Skip to content
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

Split prisma schema into multiple files #25

Open
juliavdkris opened this issue May 17, 2024 · 1 comment
Open

Split prisma schema into multiple files #25

juliavdkris opened this issue May 17, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@juliavdkris
Copy link
Contributor

Sooo we're back to using prisma, which is cool and all, but it doesn't have support for splitting your db schema over multiple files. There's this cool library called prisma-import that might help with this.

For now I'll just keep it in one file, since that's what's officially supported. But in the future it might be worth checking this out.

There is also an open issue in the prisma repo for tracking official support: prisma/prisma#2377. Two PRs for this functionality have already been merged (prisma/prisma-engines#4243 and prisma/prisma-engines#4787), so it's probably coming soon :)

@juliavdkris juliavdkris added the enhancement New feature or request label May 17, 2024
@juliavdkris juliavdkris self-assigned this May 17, 2024
@muslimakhan
Copy link

Hey @juliavdkris, please check my blog and script here:
New Trick – Organizing Prisma Models with the MERN Stack
Github Repo

This script could be help in both model split into multiple files and also for enum & types of Prisma ORM. And there is also a way to import predefined data into database too.
Hope, it would be solve your problem.
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants