validators property
Several predefined validators can be used to validate the field.
For example, required
, email
please see the validators reference
If you want to use your own validator, you can use custom
type
and add your own validator function. The function must return a null
if the field is valid or a string with the error message if the field is invalid.
Implementation
final List<Map<FieldValidator, dynamic>>? validators;