11/3/2018 - 2:53 PM


caso de pau para criar o react app via npm

On a recent assignment, I needed to install npm behind a corporate proxy. I had already set the environment variables HTTP_PROXY and HTTPS_PROXY. Other command line utilities, like ruby gems, recognized these environment variables. Npm did not.

After some googling, I found the following way to configure the proxy for npm.

npm config set proxy
npm config set https-proxy

If you need to specify credentials, they can be passed in the url using the following syntax.