NPM is really slow performing simple tasks

Viewed 44

Everything I do with NPM takes several minutes; especially npm install, even if I already have all the packages installed. I first thought the problem is that the old code I am working with just takes longer to update (because last time an older npm version was used) but the problem percists even if I repeat the process.

My system and other Information:

  • Windows 11 PC
  • Ubuntu 18.04.5 VM from the Microsoft Store
  • VS Code.
  • npm version 8.19.2
  • node version 16.17.0
  • From my package-lock.json file: "lockfileVersion": 2
  • I usally have 5 to 10 dependecies listed in my package file
  • My internet speed is around 25 MB/s

What I tried so far with no luck:

  • A newer Version of Ubuntu
  • Using http instead of https a la:
npm config set registry http://registry.npmjs.org/ --global

as was suggested in 'npm install' extremely slow on Windows. It seems to me it still tries to connect to the https address (at least that's what it looks like if I use npm install --verbose to show more feedback).

No matter what I still sit here, wasting ages waiting for my npm install.

0 Answers
Related