These are some react-redux
wrappers/containers for the redux-field
module. Because redux-field
is not always used with React these are split into a dedicated module.
Use this when you want to attach action handlers (onBlur, onChange, onFocus, onInput, onSubmit
) and result value
to an input field. @see connectInput getFormEvents
Over Simplified Example:
Make sure you send the wrapped input a prefix
property.
import { connectInput } from 'redux-field-connect'
function InputEl(props) {
return <input {...props} />
}
const Input = connectInput(InputEl)
function CoordsInput() {
return <Input id="coords" prefix="coords" type="text" size="50" />
}