customValidation static method
Allows custom validation logic with a callback function.
Returns true
if the custom validation passes, otherwise false
.
Example:
IstValidator.customValidation("hello", (value) => value.length > 3); // true
Implementation
static bool customValidation(String value,
{List<FormValidatorRule> rules = const []}) {
return rules.every((rule) => rule.validate(value) == null);
}