I recently tried to upgrade my node version from v16.20.2 to v18.7.1 by compiling from the source code. I have since given up on that idea and I'm just going to use packages compatible with Node v16.20.2 and npm-8.19.2-1.16.18.1.3.el7.x86_6 to be on the safe side. Now I want to remove the version of NPM leftover from all of this.
Now when I run npm -v, it gives me this.
npm WARN cli npm v10.0.0 does not support Node.js v16.20.2. This version of npm supports the following node versions:
^18.17.0 || >=20.5.0. You can find the latest version at https://nodejs.org/. 10.0.0
I tried using the npm uninstall command
npm uninstall v10.0.0
that I was told to do at this post but when I run npm -v afterwards, I get the same reponse as last time.
Is there any way to remove specific versions or downgrade NPM on Amazon Linux 2 devices?