Skip to main content

Node.js

Managing Pre-existing Global NPM Packages After Installing NVM

·244 words·2 mins
Today I encountered a problem: After installing nvm, the path for installing global packages changed, making it impossible to directly remove previously installed global packages using npm uninstall -g. How did I discover this? A long time ago, I installed a global package that could be executed directly from the terminal using a command. But because it was so long ago, when I tried to upgrade that package, I found it wasn’t listed in npm list -g.