Error npm is known not to run on Node.js v10.24.1 and how to fix it, don't update to the latest version?
I run : npm run dev Error : npm is known not to run on Node.js v10.24.1 I have researched and know the command: npm install -g npm@latest and some other commands to fix the problem But the problem is that my project is using nodejs 10 so it can't use the latest nodejs. So is there any way to fix the above error. Thank you UPDATE : I use nvm to install and manage versions of nodejs. And my OS is macOs
The problem for me was upgrading my global version of npm while on an incompatible version of Node (8.16.1). I tried to uninstall npm globally but that also didn't work because I could not use the npm command. To fix it, I used nvm to switch to a compatible version of Node (nvm use 14.0.0 - this can be any version of Node compatible with the npm version you have installed globally). This allowed me to run npm commands so I ran npm uninstall -g npm first of all to remove my global version of npm and then nvm uninstall 8.16.1 to remove my faulty Node version. May need to deactivate first: nvm deactivate https://stackoverflow.com/a/38776277/15435022 I was then able to reinstall Node 8.16.1 (nvm install 8.16.1), and with it came a fresh install of a compatible npm version.
Get this solution programmatically \u2014 free, no authentication.
curl https://depscope.dev/api/error/ecf1e8f8f97d163ef52473ed4dcecfad963cdaf46c97e1ab78462eda3c6f6925