Replies: 1 comment 1 reply
-
hi @elecdeer Thank you for opening the discussion. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I noticed that Conform's automatic type coercion and
coerceFormValue
do not convertz.literal(0)
orz.literal(true)
.While we can force the conversion by writing
z.number().pipe(z.literal(1))
andz.boolean().pipe(z.literal(true))
respectively, this feels awkward as a schema definition.Should Conform support these cases?
A practical use case would be a checkbox to confirm agreement to terms and conditions.
Related
Beta Was this translation helpful? Give feedback.
All reactions