Feature Request: I want to make the validation rules conditional on button clicks. #12182
Unanswered
toki-developer
asked this question in
Q&A
Replies: 1 comment
-
you can get the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
I want to switch validation when there are multiple buttons on one form.
For example, if I have "Save Draft" and "Finalize", I want to make only the "Finalize" one "Required".
Describe the solution you'd like
Allow multiple validation resolvers to be registered, so that the validation can be selected and executed by a button clicked.
Describe alternatives you've considered
Functionality to register validations with id in useForm and switch between validations by passing the id of the validation as an argument to the handleSubmit function.
Beta Was this translation helpful? Give feedback.
All reactions