Python and go have similar issues though. People do not audit and do no vendor their dependencies.
With NPM, just typing `npm update` can pwn your workstation.
This feels more like a numbers issue than a fundamental difference, i.e. Python packages generally have orders of magnitude fewer dependencies than JS ones because the standard library is very extensive. Most dependencies are major libraries rather than small ones, which are much less likely to be compromised.