See the two commits in this repo.
The first commit is the result of running:
> npm install @pmmmwh/react-refresh-webpack-plugin@0.5.9 read-pkg-up@7.0.1
added 135 packages in 6s
This command exits without error, and correctly installs to node_modules/ and package-lock.json. However, the resulting tree is invalid, according to npm ci
:
❯ npm ci
npm ERR! code EUSAGE
npm ERR!
npm ERR! `npm ci` can only install packages when your package.json and package-lock.json or npm-shrinkwrap.json are in sync. Please update your lock file with `npm install` before continuing.
The second commit is the result of running npm install
again. This updates the package lock to a valid tree, and npm ci
now completes successfully.
It shouldn't be necessary to run npm install
twice to get a valid tree.
See current behavior for a minimal repro repository.
npm view <pkg>@<spec>
prints the package information for every matching version of that package.
I expect it to print the package information for only a single version (the resolution of the spec, as with npm install <pkg>@<spec>
). This was the behavior in npm@8. I don't see this mentioned as an intentional change in the changelog, so it seems like a regression.
npm@9
.npm view react@18
.react@18.0.0
, react@18.1.0
, and react@18.2.0
).npm@8
.npm view react@18
.react@18.2.0
).; n/a
Default to Node 18 target in library envs (#122)