You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a yup object with a custom validation (test) which relies on the entire object. As validation is only triggered on changing fields, this test is never ran. It would be good if there was a way to trigger validation on the entire form/nested form. (e.g. add the validateOn/noValidate props to Form/NestedForm).
For now I have done this as a work around (code is copied from NestedForm and modified so it will run the validation on it):
I've rewritten NestedForm for my project now, it takes nameOrOptions as string | UseFieldOptions and also handles a few other things around validation to get it to work correctly. Happy to put in a PR for this!
I have a yup object with a custom validation (
test
) which relies on the entire object. As validation is only triggered on changing fields, this test is never ran. It would be good if there was a way to trigger validation on the entire form/nested form. (e.g. add the validateOn/noValidate props to Form/NestedForm).For now I have done this as a work around (code is copied from NestedForm and modified so it will run the validation on it):
Thanks!
The text was updated successfully, but these errors were encountered: