0

I just installed Node.js and npm (version 4.1.1, Windows 7 64 bit). When I try any npm command, I get a URI error list, similar to that given here: npm error question on SO I see many people mentioning the proxy setting, but I cannot set the proxy in npm either; I get the same error for any npm command. (My proxy settings appear to be correct in the .npmrc file in my user folder) I have re-installed Node.js (making sure to delete AppData/Roaming npm files as well), to no effect. I am and administrator on this machine.

Community
  • 1
  • 1
JasonBK
  • 539
  • 3
  • 12
  • 37

2 Answers2

0

This worked for me: uninstalled node.js and npm, and deleted .npm files in User/username/AppData/Roaming folder

re-installed node.js/npm

then, in command line:

npm config set registry http://registry.npmjs.org

then removed reference in npmrc file (in users/username directory) to proxy:

npm config rm proxy npm config rm https-proxy

JasonBK
  • 539
  • 3
  • 12
  • 37
0

I encountered this when I was under a company proxy. The solution that worked for me:

  • uninstall node
  • remove everything from .npmrc file (usually , here is set the proxy) My .npmrc file was under users/user/.npmrc
  • Restart computer
  • Reinstall node
  • Set the proxy again like this: Using npm behind corporate proxy .pac
Community
  • 1
  • 1
aciurea
  • 51
  • 6