Skip to content

SchemaBuilderOptions ​

The options of createSchemaBuilder.

Definition ​

  • SchemaBuilderOptions
    • kinds Record<string, KindDef>: your own kinds, merged over the built-in ones
    • fieldTypes Record<string, FieldTypeDef>: your own field types, merged over the built-in ones
    • rules Record<string, RuleDef>: your own rules, merged over the built-in ones
    • formRules Record<string, FormRuleDef>: your own form rules, merged over the built-in ones
    • includeDefaultRules boolean: with false, only your own rules and form rules. Defaults to true
    • messages { required?: string }: the required message of fields without their own. Defaults to 'Required'
    • resolveMessage (key: string, ctx: MessageContext) => string | undefined: translates every message, label and description. undefined keeps the text
    • extensions readonly SchemaExtension[]: features that read keys of their own, like affects()

Explanation ​

Every option is optional. See messages and i18n for messages and resolveMessage, and extensions for extensions.

Functions ​

Types ​