0

I am trying to install npm packages but it keeps giving me errors about network connectivity. I have tested by changing the registry

// 1st 
npm config set registry "https://registry.npmjs.org"
2nb
npm config set registry "http://registry.npmjs.org"

but it didn't work.

Node Version - 16.8.0

npm Version - 7.21.0

Error picture

I have no idea how to solve it regardless of seeing/trying so many solutions on the internet. Please help.

  • does ping works ? aka ```ping https://registry.npmjs.org/``` – bogdanoff May 17 '22 at 14:58
  • `%2f` is a url-encoded slash, but I'm wondering why the URL in the error message uses that instead of an actual slash. The proper URL works fine: https://registry.npmjs.org/@babel/preset-env So this is not really a network issue, it's an encoding issue. –  May 17 '22 at 14:59
  • Earlier it was downloading packages but from yesterday when I was trying to install @babel/core and @babel/preset-env this issue was occurring. – Tazim Rahbar May 17 '22 at 17:19

0 Answers0