-
Notifications
You must be signed in to change notification settings - Fork 170
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
Should threejs be changed to a peer dependency? #1021
Comments
Honestly, I don't know.... In your experience, how using |
Right now, since I have lint rules set up forbidding importing dependencies that are not in my package.json, I have to add
That user shouldn't be using an updated version of three since it is liable to break NGL though, right? Or are you arguing for the case of the user creating a separate three app that never interacts with NGL? In the latter case I suppose that would be an issue. I suppose you could make an argument that you should just import ngl's version without adding it to the main package.json, and in my case that just means adding lint rule exclusions. Though it could still create problems if another dependency is used which also has three as a dependency or peer dependency of a conflicting version |
#728, #755, and related issues discuss the use case of using NGL in downstream projects that also need to use threejs as a dependency, eg because NGL is embedded into an existing threejs app or a downstream app wants to extend NGL somehow (eg, adding a custom representation). To further support this use case, I'm wondering if it would make sense to make threejs a peer dependency instead of a regular dependency. This would ensure that only one copy on threejs is in play, and its version is always synced with the one required by NGL.
The text was updated successfully, but these errors were encountered: