Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
zod-prisma
Advanced tools
<!-- *** Thanks for checking out the Best-README-Template. If you have a suggestion *** that would make this better, please fork the repo and create a pull request *** or simply open an issue with the tag "enhancement". *** Thanks again! Now go create som
A custom prisma generator that creates Zod schemas from your Prisma model.
Explore the docs »
View Demo
·
Report Bug
·
Request Feature
I got tired of having to manually create Zod schemas for my Prisma models and of updating them everytime I made schema changes. This provides a way of automatically generating them with your prisma
To get a local copy up and running follow these simple steps.
This project utilizes yarn and if you plan on contributing, you should too.
npm install -g yarn
Add zod-prisma as a dev dependency
yarn add -D zod-prisma # Not yet published
Add the zod-prisma generator to your schema.prisma
generator zod {
provider = "zod-prisma"
output = "./zod"
relationModel = "default"
}
Run npx prisma generate
to generate your zod schemas
Import the generated schemas form your selected output location
TODO
For examples, please refer to the Examples Directory or the Functional Tests
See the open issues for a list of proposed features (and known issues).
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
git checkout -b feature/AmazingFeature
)git commit -m 'Add some AmazingFeature'
)git push origin feature/AmazingFeature
)Distributed under the MIT License. See LICENSE
for more information.
Carter Grimmeisen - Carter.Grimmeisen@uah.edu
Project Link: https://github.com/CarterGrimmeisen/zod-prisma
FAQs
A Prisma generator that creates Zod schemas for all of your models
The npm package zod-prisma receives a total of 6,556 weekly downloads. As such, zod-prisma popularity was classified as popular.
We found that zod-prisma demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.