Search code examples
node.jsvisual-studio-codenpm

npm is installed but VS Code terminal says "Command npm not found". But other Ubuntu terminal runs npm easily. What is the issue?


When I try to run "npm" from VS Code terminal, I get the error "Command 'npm' not found."

Now, when using other Ubuntu terminal, the npm runs flawlessly. npm has been installed. However, in VSCode terminal window, neither node.js nor npm is found to be installed.

What am I missing here?

I tried reinstalling npm but didn't work.


Solution

  • I'm not sure about ubuntu but for mac you can change the shell vscode is using if your vscode shell and the one in terminal differs then you can change the one vscode is using: VSCode shell type