Files
firecms/website/docs/api/interfaces/fieldconfig.md
2021-06-06 13:36:47 +02:00

1.7 KiB

id, title, sidebar_label, sidebar_position, custom_edit_url
id title sidebar_label sidebar_position custom_edit_url
fieldconfig Interface: FieldConfig<T, CustomProps> FieldConfig 0 null

Configure how a field is displayed

Type parameters

Name Type
T T
CustomProps CustomProps = any

Hierarchy

Properties

customProps

Optional customProps: CustomProps

Additional props that are passed to the components defined in field or in preview.

Defined in

models/models.ts:821


field

Optional field: ComponentType<FieldProps<T, CustomProps, EntitySchema<any, any>, any>>

If you need to render a custom field, you can create a component that takes FieldProps as props. You receive the value, a function to update the value and additional utility props such as if there is an error. You can customize it by passing custom props that are received in the component.

Defined in

models/models.ts:808


preview

Optional preview: ComponentType<PreviewComponentProps<T, CustomProps>>

Configure how a property is displayed as a preview, e.g. in the collection view. You can customize it by passing custom props that are received in the component.

Defined in

models/models.ts:815