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
However, this does not help when validating for example, blur events. Instead an error is caused as the context is undefined and my validation relies on context.
The text was updated successfully, but these errors were encountered:
Yeah it would be nice if it is possible to send a parameter to validationSchema. It is a bit weird knowing this is not default behavior for on yup. I am also stuck, and when() is not what I am looking for since I want to be able to control what to validate based on variable outside of the form.
Feature request
Be able to pass a context object to yup in conjunction with validationSchema
Current Behavior
Context is undefined when it is passed to Yup for validation.
Desired Behavior
Able to pass in a context object to the Formik form that will be sent when validationSchema is called
Suggested Solution
Add a validationContext attribute
Describe alternatives you've considered
This may be possible with:
However, this does not help when validating for example, blur events. Instead an error is caused as the context is undefined and my validation relies on context.
The text was updated successfully, but these errors were encountered: