help icon indicating copy to clipboard operation
help copied to clipboard

npm doesn't work in PowerShell, only npm.cmd does

Open OksanaMala opened this issue 1 year ago • 25 comments
trafficstars

Node.js Version

v20.15.0

NPM Version

v10.8.0

Operating System

Windows 11 Pro

Subsystem

console, Other

Description

In PowerShell terminal, the npm command doesn't work; only npm.cmd works. However, in Command Prompt, the npm command works. To troubleshoot, I have reinstalled Node.js, PowerShell, checked environment variables, confirmed the path is set correctly, and npm.cmd exists in the nodejs folder.

Minimal Reproduction

No response

Output

No response

Before You Submit

  • [X] I have looked for issues that already exist before submitting this
  • [X] My issue follows the guidelines in the README file, and follows the 'How to ask a good question' guide at https://stackoverflow.com/help/how-to-ask

OksanaMala avatar Jul 04 '24 09:07 OksanaMala