Skip to content

Demos

Empty

<Field.FirstName onChange={(value) => console.log('onChange', value)} />

Placeholder

<Field.FirstName
placeholder="Enter a name..."
onChange={(value) => console.log('onChange', value)}
/>

Label

<Field.FirstName
label="Label text"
onChange={(value) => console.log('onChange', value)}
/>

Label and value

<Field.FirstName
label="Label text"
value="John"
onChange={(value) => console.log('onChange', value)}
/>

Disabled

<Field.FirstName
value="John"
label="Label text"
onChange={(value) => console.log('onChange', value)}
disabled
/>

Error

This is what is wrong...
<Field.FirstName
value="Unnamed"
label="Label text"
onChange={(value) => console.log('onChange', value)}
error={new FormError('This is what is wrong...')}
/>

Validation - Required

<Field.FirstName
value="John"
label="Label text"
onChange={(value) => console.log('onChange', value)}
required
/>