Generate Zero schema files from Prisma ORM schemas. This generator (v0.1.3) is an early-stage tool that automatically creates table definitions, column mappings, and type-safe schemas compatible with Zero (the reactive sync engine from Rocicorp). It supports all standard Prisma data types, Postgres arrays (mapped to json<>), DateTime/Time types, enums, and optional fields. Ideal for developers migrating from Prisma to Zero or building apps that need both Prisma's schema management and Zero's real-time sync. Not yet stable; expect breaking changes in minor versions. Differentiates from @passionfroot/prisma-generator-zero by being officially maintained by Rocicorp.
npm install prisma-zeroNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to install the generator, configure it in Prisma schema, and use the generated schema with Zero's createSchema.
Pin exact version and review changelog before upgrading.
Remove these options and migrate to the new mutator API as described in Zero docs.
Update @rocicorp/zero to 0.26.0 or later.
Consider whether json columns are acceptable for your use case; plan accordingly.
Run `npm install @rocicorp/zero` and ensure it is in your package.json.
Run `npm install prisma-zero` and regenerate with `npx prisma generate`.
Import table from your generated schema file (e.g., `import { table } from '../generated/zero-schema'`).