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

Move prisma and prisma/client to peerDependencies and not direct dependencies? #67

Open
zackdotcomputer opened this issue Mar 19, 2025 · 1 comment

Comments

@zackdotcomputer
Copy link

Currently the prisma and @prisma/client packages are listed as dependencies of this package. In practice, however, this package is always going to be used alongside those packages rather than expected to be in charge of managing those packages as dependencies. Therefore, I suggest we move those two to being peerDependencies instead of direct dependencies. This will avoid hard dependency conflicts or duplication if the user tries to use a version of prisma that's officially outside of the supported range of this package (whereas currently if we try to upgrade to prisma 6 while using this package, yarn installs both versions alongside each other instead of just giving a verbal warning about the mismatch).

@Brakebein
Copy link
Owner

Yes, it should be possible. I have recently upgraded from Prisma 4 to 5 and had to adapt some code, because the Prisma schema parser uses more strict types. But it should be backward compatible. Then, I will also need to test it for Prisma 6, and I will move any Prisma dependencies to peerDependencies section.

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

No branches or pull requests

2 participants