npm ERR! Hostname/IP doesn’t match certificate’s altnames: "Host: registry.npmjs.org. is not in the cert’s altnames: DNS:*.smartdnsproxy.com, DNS:smartdnsproxy.com"
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR! https://github.com/npm/npm/issues
Please do not listen to the advice in the previous post. Never run node as a superuser. There is never a need to do so and it can cause problems that are very difficult to untangle. Please use nvm instead.