-
-
Notifications
You must be signed in to change notification settings - Fork 194
Add base64 support for zod #2267
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
base: main
Are you sure you want to change the base?
Conversation
|
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
commit: |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2267 +/- ##
==========================================
- Coverage 24.80% 24.79% -0.01%
==========================================
Files 299 299
Lines 28297 28305 +8
Branches 1276 1276
==========================================
Hits 7018 7018
- Misses 21270 21278 +8
Partials 9 9
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
@ligazetom I'll say go for it, simply because there's no conflicting implementation and you're the first one to request this format. You just need to run |
Hey, take this as a bit more elaborate feature request as I have no idea what I'm doing really.
This PR should generate
.base64()
constraint ifformat: byte
. If it doesn't, then I think it should :DCurrently I'm doing some post processing on generated zod file to add
base64()
constraint as well astrim()
.I have no idea if
trim()
could be somehow implemented, but I believe no one really considers whitechars valid, so can it be done at least with some flag maybe?Let me know if 'implementation' is not total garbage and I'll adjust tests as well, I just don't have really time to spare on these things if the PR maybe won't get even looked at.