Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zod optional field with default value become required #73

Open
mil920 opened this issue Apr 12, 2024 · 0 comments
Open

Zod optional field with default value become required #73

mil920 opened this issue Apr 12, 2024 · 0 comments

Comments

@mil920
Copy link

mil920 commented Apr 12, 2024

Hi,
I don't kown why i have a optional field in my zod schema when i put a default value for edit action.
My field become required but i don't want that because it's filled by my model value or empty,
so why it's required ?
Am i doing something wrong ?
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant