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 find that there are times when I wish I could validate against a more basic schema than the one I've defined. Say I have a schema that I use for form/server validation.
I'm wondering if there is a way to strip extended validation properties from a schema. The schema defined above could be stripped down to the following
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I find that there are times when I wish I could validate against a more basic schema than the one I've defined. Say I have a schema that I use for form/server validation.
Sometimes, before populating a form I'd like to make sure that some unverified data I'm passing to it has the general shape expected by the schema.
I'm wondering if there is a way to strip extended validation properties from a schema. The schema defined above could be stripped down to the following
This would allow me to validate against the shape of the data without having to validate against extended props like
min/max
.Beta Was this translation helpful? Give feedback.
All reactions