custom method

FormValidator custom({
  1. String? message,
  2. required bool validate(
    1. dynamic data
    ),
})

Validate a custom rule message The message to display if the custom validation fails validate The custom validation function that takes the data and returns a boolean

Implementation

FormValidator custom({
  String? message,
  required bool Function(dynamic data) validate,
}) {
  _addRule(FormRuleCustom(message: message, customValidation: validate));
  return this;
}