author avatar

adithya.hebbar

Wed May 29 2024

To generate an Entity-Relationship Diagram (ERD) using Prisma-erd-generator, follow these steps :
Install the following package


npm i -D prisma-erd-generator @mermaid-js/mermaid-cli
# or
yarn add -D prisma-erd-generator @mermaid-js/mermaid-cli


Add this to your schema.prisma


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


Run the generator


npx prisma generate


#javascript #erd