-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Add support for base64url
strings
#3711
Comments
marvinruder
added a commit
to marvinruder/zod
that referenced
this issue
Aug 16, 2024
Fixes colinhacks#3711 Signed-off-by: Marvin A. Ruder <signed@mruder.dev>
marvinruder
added a commit
to marvinruder/zod
that referenced
this issue
Aug 30, 2024
Fixes colinhacks#3711 Signed-off-by: Marvin A. Ruder <signed@mruder.dev>
colinhacks
pushed a commit
to marvinruder/zod
that referenced
this issue
Dec 10, 2024
Fixes colinhacks#3711 Signed-off-by: Marvin A. Ruder <signed@mruder.dev>
colinhacks
added a commit
that referenced
this issue
Dec 10, 2024
* Add support for `base64url` strings Fixes #3711 Signed-off-by: Marvin A. Ruder <signed@mruder.dev> * Add comments Signed-off-by: Marvin A. Ruder <signed@mruder.dev> * Change test structure for `base64()`, `base64url()` Signed-off-by: Marvin A. Ruder <signed@mruder.dev> * Prettier * Avoid test.each --------- Signed-off-by: Marvin A. Ruder <signed@mruder.dev> Co-authored-by: Colin McDonnell <colinmcd94@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The
.base64()
function validates strings that contain binary information encoded in Base 64. A modification of Base 64 that can safely be used in URLs and filenames is given by thebase64url
standard specified in RFC 4648 § 5. As summarized here,I propose a method
.base64url()
that is similar to.base64()
, but instead matches against a regular expression that describesbase64url
-encoded values.The text was updated successfully, but these errors were encountered: