Releases: davidkpiano/react-redux-form
React Redux Form v0.14.4
UMD Build
Thanks to the work by @mdgbayly, React Redux Form now builds a proper UMD build: #341 🎉
We'll be tweaking this to make it more easily accessible in demos and examples in the documentation.
Version 1.0 Beta
Also, Version 1.0 beta is out, and can be downloaded via npm install react-redux-form@beta
. I will be writing the new documentation soon and there are still a bunch of features to be added, so only play around witht his if you're curious right now. The biggest breaking change is around the simplification of the formReducer
and the ability to use plugins with it (so it's a good breaking change), and everything else remains largely the same, with some fun performance enhancements and extra features.
React Redux Form v0.14.3
Immutable <Field>
- This patch introduces
Field
for ImmutableJS, and a new (internal)getter
prop for the<Field>
component that tells RRF how to "get" the value given thestate
andmodel
.
import { Field } from 'react-redux-form/lib/immutable';
// use with immutable model reducers
<Field model="...">
React Redux Form v0.14.2
Tracking Enhancement!
- Now, all actions can take a "model tracking function" as their first argument instead of a
model
string. This allows you to dynamically track which model you want based on the predicate. More info here: https://davidkpiano.gitbooks.io/react-redux-form/content/tracking_collections.html
import { actions, track } from 'react-redux-form';
// ...
dispatch(actions.change(track('team.members[].name', { id: 123 }), 'John'));
// will find the model path for the member in the team.members array
// and change only that member's name to "John"
Fixes
- Validation will no longer run before submit on
<Form validateOn="submit">
. #312
React Redux Form v0.14.1
Fixes and Enhancements
- Validation actions such as
setValidity
,setFieldsErrors
andsetErrors
are optimized in<Field>
and<Form>
to only dispatch when the validity has actually changed, instead of dispatching on every single change. - The edge case where the numeric value
0
resulted in an empty<input />
text field has been resolved: #311 - TypeScript definition file updated: #310
React Redux Form v0.14.0
React 15.2.0 Support 🎉
- This minor version doesn't break anything, but now supports the latest React v.0.15.2 by mitigating warnings caused by unknown properties appearing on DOM elements. This blacklists the
propTypes
from the following components:<Field>
<Form>
<Control>
<Errors>
See #304 for more info.
Enhancements and Fixes
- The
<Errors>
component should no longer render anything if there are no errors. #309 - The TypeScript definition file has been updated, thanks to @asvetliakov!
An alpha release for V1.0 is coming soon! If there are super important features you would like included in this version, feel free to open an issue marked with [V1.0]
.
React Redux Form v0.13.11
Quick Fixes
- Sanity check for
fieldValue
in<Control>
to see if validation should be reset upon unmount. - Sanity check for
node
inattachNode()
method of<Form>
to see if it is attachable.
React Redux Form v0.13.10
Enhancements and Fixes
- Controls (from
<Field>
) will now have their validity reset if they are unmounted. TheresetValidity
action is dispatched on unmount if and only if the validity has changed. - There is now full support for
<input type="file" />
! 🎉 - Also,
<input type="reset" />
inside a<Field model="...">
will dispatch areset
action to that model when clicked.
Programmatically Submitting Forms
React Redux Form v0.13.8
Handling (Un)Controlled Components
- The
<input>
value now defaults to the empty string''
if themodelValue
is falsey for text inputs. - If
defaultChecked
is specified on radio or checkbox components, then RRF won't attempt to control the component. #265
Enhancements and Bug Fixes
- Validity will now be reset when a
<Field>
or<Control>
(internal) is destroyed. - Async actions in
asyncSetValidity
are now batched, which means less rerendering, less reducer calls, less dispatches, better performance. #277 - Async validators in
<Field>
now merge the validity with the existing (sync) validity instead of overwriting it. #277
React Redux Form v0.13.7
Improvements
- Removed the unnecessary dependency on
flat
! 🎉 - The
<Errors>
component now returnsnull
instead of an empty<div>
when there are no errors to be displayed. #266 - (Internal) The
getFormStateKey(...)
function has been optimized for performance. #262
Bug Fixes
<Field>
components now properly trigger validation again when their model changes (even indirectly, e.g., from anaction.merge(...)
or a parent model update). #264
React Redux Form v0.13.6
Custom Components and createFieldClass()
- If you specify the
.componentMap
in thedefaultProps
argument (second arg) ofcreateFieldClass(propsMap, defaultProps)
, it will now recognize custom components based on their constructors, and not on their.displayNames
(which are minified in production builds). #261 #224 #176 #161 #65
import CustomInput from '../somewhere/custom-input.js';
import { createFieldClass, controls } from 'react-redux-form';
// BEFORE:
const CustomField = createFieldClass({
CustomInput: controls.text,
});
CustomField.displayName = 'customField'; // < 0.13.6 workaround
// AFTER:
const CustomField = createFieldClass({
CustomInput: controls.text,
}, {
componentMap: {
CustomInput: CustomInput // recognize custom input from constructor
}
});
// SHORTHAND:
const CustomField = createFieldClass({
CustomInput: controls.text,
}, {
componentMap: { CustomInput }
});
Bug Fixes