I created an index.js, index.html and package.json file and I wanted to add express. When I write \'npm install express\' in the terminal, I\'m getting the error below. So far,
The error means that you have no permission to install anything with npm at the path /npm
.
To verify this run npm root -g
. This should return /npm
.
Note that /npm
ist not the default installation path on MacOS (see https://stackoverflow.com/a/35638528/1754076).
Checkout your npm configuration file and change the default installation path to something where you do have write access. You can also use npm itself to change the default installation path.