New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@passionfroot/prisma-generator-zero

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@passionfroot/prisma-generator-zero

A Prisma generator for generating Zero schema with ease

  • 0.0.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

prisma-generator-zero

prisma-generator-zero is a generator for prisma that generates a Zero schema from your Prisma schema. This includes schemas of models, enums, and relationships.

Known issues and Limitations

  • The generator doesn't currently handle permissions, so the generated schema will default to allow any read/write operation. We'd love to add better support for this in the future and welcome contributions!

Installation

npm install @passionfroot/prisma-generator-zero

Usage

Add a new generator to your prisma.schema:

generator zero {
  provider       = "prisma-generator-zero"
}

Then run the following command to generate the schema.ts file in the ./generated/zero output folder:

npx prisma generate

You can directly use the generated schema as explained here and/or reference specific exports anywhere else in your code.

If you want to customize the behavior of the generator you can use the following options:

generator zero {
  // Specify output dir
  output   = "generated/one"
  // When true, the output will be formatted using prettier
  prettier = true
  // By default, the generator will keep track of changes to the schema and automatically bump the version.
  // You can opt-out from this behavior by setting `schemaVersion`.
  schemaVersion = 10
}

Keywords

FAQs

Package last updated on 09 Jan 2025

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc