If I create a new AWS instance (ubuntu 16.04 LTS) and create a directory (NodeT) then run the 2 commands:
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get install -y nodejs
( from https://nodejs.org/en/download/package-manager/ )
I then have successfully installed node and npm?
node -v
npm -v
return their versions.
So have I created it locally on NodeT or globally on the whole system? Where is the node_modules directory?
I am trying to install mongodb on the system and am having troubles. I believe I need to run:
nodejs node_modules/node-sass/scripts/install.js
npm rebuild node-sass
( from https://github.com/sass/node-sass/issues/1579 ) to solve my problems, but the command can't find the node_modules directory and either can I.
I'm clearly missing the basic concept of nodejs. Any help would be appreciated.
type this command in your terminal
sudo npm root -g
Output (example):
/usr/local/lib/node_modules
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With