Skip to content

useFieldValidation

Overview

Dispatches to the validation composable matching the given type string. Does nothing when type is undefined or unrecognized.

Signature

useFieldValidation(type, fieldContext, options)

Parameters

NameTypeRequiredDescription
typestringyesThe validation type (e.g. "text", "numeric", "decimal", "date", "datetime", "time").
fieldContextFieldContextyesThe field context to validate against.
optionsanyyesConstraint configuration (typically the component props object).

Returns

void

Source

client/lib/use/validation/useFieldValidation.js:31

Documents matching: server v3.0.0a1.post1client v3.0.0-alpha.2