8000 Zod Progress · Issue #35 · vitalics/ajv-ts · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Zod Progress #35

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

Open
5 of 25 tasks
vitalics opened this issue Jan 23, 2024 · 2 comments
Open
5 of 25 tasks

Zod Progress #35

vitalics opened this issue Jan 23, 2024 · 2 comments
8000
Assignees
Labels
enhancement New feature or request zod
Milestone

Comments

@vitalics
Copy link
Owner
vitalics commented Jan 23, 2024

As a part of this issue, we need to propose a way to compatibility of zod API.

issue motivated from #32

here is a list of features that zod has:

Add comments if I missed something

@vitalics vitalics added enhancement New feature or request zod labels Jan 23, 2024
@vitalics vitalics added this to the Zod milestone Jan 23, 2024
@vitalics vitalics self-assigned this Jan 23, 2024
@miguelrk
Copy link
miguelrk commented Jan 23, 2024

As an additional note, I see 2 alternative ways of doing this:

  1. aliasing: adding the extra props to the current API (e.g. adding literal and shape alongside const and schema)
  2. refactoring: renaming duplicate fields to their zod counterparts and exposing them exclusively (e.g. const -> literal, schema -> shape

Both approaches would work, just thought it might be good on deciding on one before pursuing this refactor 👍🏼

@vitalics
Copy link
Owner Author

I like aliasing since current implementations are pretty close to JSON-schema naming.

@vitalics vitalics pinned this issue Feb 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request zod
Projects
None yet
Development

No branches or pull requests

2 participants
0