Closed colinhacks closed 4 months ago
This is unrelated but you could use pattern
to enforce toLowerCase
/toUpperCase
/trim
. e.g. you can use /^[^A-Z]*$/
for .toLowerCase()
. You're right that those are "mutating" checks..but ultimately they do refine the output type meaningfully.
Thanks for contributing! I think the confusion about the mutating checks was mostly about the nomenclature, and the good old input/output target question. V4 will give us a chance to clear all that up for good :)
Just to get you started :)
Currently a beta version of
zod
is hard-coded into the package.json so you'll want to update that before merging.