Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot create required if custom validator #278

Open
ahmedthinkdifferent opened this issue Nov 12, 2021 · 1 comment
Open

cannot create required if custom validator #278

ahmedthinkdifferent opened this issue Nov 12, 2021 · 1 comment

Comments

@ahmedthinkdifferent
Copy link

i need to check that value is exists if field exists and in another scenario wants to validate that value is exists if field exists with this custom value.
{
"gender":"male",
"age"20
}
want to check that age exists if gender exists.
second scenario.
{
"gender":"male",
"age"20
}
wants to check that age exists if gender is male because females don't like others ask for their ages.
Thanks

@srcnix
Copy link

srcnix commented Feb 28, 2023

Use 'check' or 'custom' property on the validator itself?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants