create-react-app: Package.json for eslint-config-react-app on NPM is incorrect
Describe the bug
The package.json
file for eslint-config-react-app
differs between NPM and Git for one peer dependency:
- Git:
"eslint-plugin-react-hooks": "1.x || 2.x || 3.x || 4.x"
- Npm:
"eslint-plugin-react-hooks": "1.x || 2.x"
Both has "version": "5.2.1"
, and everything else matches, except for this one peer dependency. π
Steps to reproduce
- Inspect package.json on git:
β"version": "5.2.1"
β"eslint-plugin-react-hooks": "1.x || 2.x || 3.x || 4.x"
- Run
npm pack eslint-config-react-app
- Inspect the
package.json
within the downloadedtgz
package:
β"version": "5.2.1"
β"eslint-plugin-react-hooks": "1.x || 2.x"
Expected behavior
Would expect the acceptable versions of "eslint-plugin-react-hooks"
to be the same in both places.
Actual behavior
Acceptable versions do not match. Means npm gives me a warning when I try to upgrade eslint-plugin-react-hooks
to its latest version, 4.x
:
> npm install eslint-plugin-react-hooks@4
npm WARN eslint-config-react-app@5.2.1 requires a peer of eslint-plugin-react-hooks@1.x || 2.x but none is installed. You must install peer dependencies yourself.
+ eslint-plugin-react-hooks@4.0.1
updated 1 package and audited 712 packages in 3.669s
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 16
- Comments: 16 (1 by maintainers)
Thank you, most gracious mr. Stale.
Still an issue. And seems to be βworseβ too. The whole
peerDependencies
section seems to be incorrect.From GitHub repo:
From NPM via
npm pack eslint-config-react-app
:Just noticed the
package.json
downloaded from Npm includes"gitHead": "d2f813f8897ffcd2f0b0d2da75d0c44924c92f4d"
, and checking thepackage.json
for that, it is indeed different thanmaster
, yet both says they are"version": "5.2.1"
.Confusing and annoying.
π€·ββοΈπ
Dear mr. Stale
This projects has not had any new releases since march, so this issue has not been fixed. Please do not close until it has been.
Humbly, Me
This is why my plugins are not getting loaded in my eslintrc. Still not stale.
This is still an issue: npm WARN eslint-config-react-app@5.2.1 requires a peer of eslint-plugin-react-hooks@1.x || 2.x but none is installed. You must install peer dependencies yourself.
This is still an issue for me too.