Skip to main content

<Field>

Render a form field using form helpers passed to the render function.

Properties

PropertyDescription
render or childrenThe render function. This function will be called with the state as it's first parameter.
fromWhat store to retrieve state from.
formWhat form to retrieve state from.
pathThe state path to retrieve. Specified as a dotted path string, with support for arrays. Sample: "my.field.path[10].name"
constantWhen true, the Field component will query state and render only once.
defaultThe default value when the state is undefined.
debugWhen true, log messages regarding state changes will be printed to the console.
verboseWhen true, verbose log messages are printed to the console.
idDebug log uses this to identify components
onMountCalled with the current state when the component mounts.
onUnmountCalled with the current state when the component unmounts.
typeWhen type is set to checkbox or radio, the value is emitted as a checked attribute instead of a value attribute.
Live Editor
Result
Loading...