Fields


Fields are added to forms via the fields array and create the editing interface of a form.

Field Config

All field plugins share a common config:

interface FieldConfig {
  name: string
  parse?: (value: any, name: string, field: Field) => any
  format?: (value: any, name: string, field: Field) => any
  component: string | ReactComponent
}
keydescription
nameEquivalent of an input's name attribute.
componentEither a string denoting a field already registered with the CMS, or a custom field component.
parseOptional: Prepare the data for usage in the field component.
formatOptional: Prepare the data for saving.