formSchemaShield
Applies the schema validation path exposed for Valyrian.js forms.
Table of contents
Category
Value
Import
jsimport { formSchemaShield } from "valyrian.js/forms";Public signature
tsformSchemaShield: SchemaShieldAPI form
formSchemaShield is the shared SchemaShield singleton used by FormStore. FormStore.schemaShield returns the same schema engine.
Common extension
tsformSchemaShield.addFormat(
name: string,
validator: (value: unknown) => boolean,
overwrite?: boolean,
): voidOther schema methods
tsaddType(name: string, validator, overwrite?: boolean): void
addKeyword(name: string, validator, overwrite?: boolean): void
compile(schema: Record<string, unknown>): ValidatorScope
Formats, keywords and types added to this singleton are available to every FormStore created afterward.