Closed alexanderanchishkin closed 2 years ago
What npm
version do you have?
npm 6.14.16
The current version is 8.x. Seems like you have an issue because of old version.
Can you update?
I will add warning for the old npm
if update will help.
Yes it works. Thanks! It would be better if you will add warning for the old npm
.
But npx browserslist-lint
still works for old versions. Maybe is it possible to save support for npm 6.x
?
the problem is with peerDependencies
in update-browserslist-db
. browserslist
has update-browserslist-db
in direct dependencies and we can’t add browserslist
to update-browserslist-db
without creating a dependencies loop.
The solution is to use old npx browserslist@latest --update-db
for now on old npm
.
I think I will add a warning and change the CLI command for old npm
.
Fixed 5974df1
Released in update-browserslist-db@1.0.5
It seems this is an environment problem, not npm 6 problem Maybe author after installing the new version of npm affected this environment But I send pr with changed text for old version on npm
Maybe. But since npm 6 is very old I do not want to spend my time on it.
When I try command "npx update-browserslist-db@latest" I got error: "Error: Cannot find module 'browserslist'". I suppose it occurs because package is installing every time I try this command (because in package.json of update-browserslist-db name of command is browserslist-lint) and package tries to require("browserslist") which can't be find from global scope. I tried npm i -g browserslist but no result. Command "npx browserslist-lint" works correctly. Is regulary installing of update-browserslist-db expected?