Skip to content

IFormFieldConfig

github-actions[bot] edited this page Dec 3, 2024 · 3 revisions
API / IFormFieldConfig<TValue, TValidationError> interface

Represents the configuration of a field, this can be extended for custom fields to easily add more features.

interface IFormFieldConfig<TValue, TValidationError = string>

Source reference: src/forms/FormField.ts:9.

Generic Parameters

  • TValue - The value of the field.

  • TValidationError - The concrete type for representing validation errors (strings, enums, numbers etc.).

    Default value: string.

Properties

  • readonly initialValue - Provides the initial value of the field.
  • readonly name - Provides the name of the field.
  • readonly optional validationTriggers - Provides the validation triggers of the field, these can be later reconfigured.
  • readonly optional validators - Provides the validators of the field, these can be later reconfigured.
  • readonly optional value - Provides the value of the field.
Clone this wiki locally