Hello Friends 🙏, today I was trying to run the npm init command and got below warnings
I thought it may be due to older node package installed on system, So installed current latest node package from https://nodejs.org/ which is v16.13.1 but sill got warning ⚠ to upgrade to a newer version of node😢 .
Then I checked the node and npm versions on my machine by running below commands
node -v //v16.13.1 npm -v //6.5.0
Checked on node website and found that node v16.13.1 ships with npm 8.1.2 🤔
Now i tried updating npm using below command but got errors 😐.
🥳 Finally I got the solution:
Issue: Installed latest node package but npm version is showing older version?
Solution: Follow below steps and 🎉🥳
- Navigate to C:\Users\<your user name>\AppData\Roaming
- Delete npm & npm-cache folders 📁
- Verify the npm version
npm -v //8.1.2