Skip to content

Instantly share code, notes, and snippets.

@nurmdrafi
Last active December 15, 2023 13:44
Show Gist options
  • Save nurmdrafi/bf6ef09e38710427b2f9efb5ad1c54c0 to your computer and use it in GitHub Desktop.
Save nurmdrafi/bf6ef09e38710427b2f9efb5ad1c54c0 to your computer and use it in GitHub Desktop.
npm config for slow internet issue

Metrics

npm config for slow internet issue

# list of npm config
npm config ls -l

# faster download
npm install --prefer-offline --no-audit --progress=false

# extend timelimit
npm install -timeout=9999999
# set npm config
npm config set fetch-retries 5 
npm config set fetch-retry-factor 20 
npm config set fetch-retry-maxtimeout 120000 
npm config set fetch-retry-mintimeout 100000 
npm config set fetch-timeout 600000 
npm config set legacy-peer-deps true 
npm config set maxsockets 50 
npm config set prefer-offline true 
npm config set progress true 
npm config set registry http://registry.npmjs.org/
npm config set strict-ssl false 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment