-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Explicitly Semantic Versioning #3099
Comments
The problem is that we dont want installations to trigger missing peer dep errors in package managers that are not aware of |
I completely understand. However, this update took place around three years ago, approximately in July 2020.
Since peerDependenciesMeta was introduced starting from npm v7, users on versions earlier than v7 might indeed find it a necessary requirement, as you mentioned. However, node.js 14, which can support npm versions below v7, has reached its End-of-Life status. Additionally, node.js 16, which mandates a minimum of npm v7, is also nearing its End-of-Life phase. Yarn] users generally operate on versions older than 1.13 from about four years ago, and similarly, pnpm users are on versions prior to 3.2.0 from around the same time, both of which do not support Furthermore, packages like As you mentioned, it's important not to trigger peer dependency errors using package managers that don't recognize I respect either approach. |
If this would be a different peer dep than |
The problem
The current package.json for @emotion/react and @emotion/styled is as follows:
This code is ultimately equivalent to the following code.
Upon verification, I learned that the addition of peerDependenciesMeta was due to errors occurring in v10.
If using Meta, I believe it would be even better to explicitly align the version of react within peerDependencies. This is why I decided to write this message. Since you've already set React to be >=16.8.0, specifying @types/react >= 16.8.0 seems safer and more suitable for common practices than using @types/react "*" indiscriminately.
Proposed solution
Explicitly adding
Alternative solutions
Additional context
#3100
The text was updated successfully, but these errors were encountered: