Closed beratbayram closed 1 year ago
You aren't missing anything, you need to mark them as required. You can wrap them and report if you want to change the defaults.
export const string = () => yup.string().required
@jquense thank you for your answer but wouldnt that make the object itself required rather than its fields?
You'd need to re-export every type you want to change the defaults for, yeah
Hi! I am new to yup and I feel like I might be missing something obvious so sorry about that in advance.
How do I set every field as required?
For example:
I have this schema but it look cluttered with all those ".required()" calls.
Is there someting like this to eliminate those calls?, for example: