[feature-request] conditional validations
xpepermint opened this issue · 1 comments
xpepermint commented
Add option to validate a field only if
specific fields are valid.
xpepermint commented
Validators and handlers now have the condition
option which switch off the recipe.
export const fields = {
email: {
validate: [
{
...
condition () { return true }
}
],
handle: [
{
...
condition () { return true }
}
]
}
};