zodex icon indicating copy to clipboard operation
zodex copied to clipboard

Added coerce support

Open miunau opened this issue 1 year ago • 4 comments

Added coerce support for string, number, bigint, date, boolean: https://zod.dev/?id=coercion-for-primitives. This is essential for working with form submissions where everything coming in is a string.

miunau avatar Apr 04 '24 13:04 miunau

LGTM, though tests would be nice

Gregoor avatar Apr 04 '24 14:04 Gregoor

Looks like this broke the tests cuz of the new property, I'll fix and add a test

miunau avatar Apr 04 '24 14:04 miunau

OK works now. @Gregoor mind merging this in? one less patchfile in my repo :)

miunau avatar Apr 04 '24 14:04 miunau

Great! I don't have merge rights here, that would be @heikir

Gregoor avatar Apr 05 '24 11:04 Gregoor