I have installed node js latest version(8.8.1) and npm latest version(5.5.1) and when i try to install node-sass i get this:
npm install -g node-sass
C:\Users\Giannis\AppData\Roaming\npm\node-sass -> C:\Users\Giannis\AppData\Roaming\npm\node_modules\node-sass\bin\node-sass
[email protected] install C:\Users\Giannis\AppData\Roaming\npm\node_modules\node-sass node scripts/install.js
'node' is not recognized as an internal or external command, operable program or batch file. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] install: node scripts/install.js
npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\Giannis\AppData\Roaming\npm-cache_logs\2017-10-26T11_57_10_751Z-debug.log
I have set the system variable C:\Program Files\nodejs\
Thanks
You can install Node. js on your Windows system using the . msi installer from the official website of Node. You can install Node.
node-sass requires node-gyp https://github.com/sass/node-sass#install
node-gyp requires windows-build-tools https://github.com/nodejs/node-gyp#on-windows
Install all the required tools and configurations using Microsoft's windows-build-tools using
npm install --global --production windows-build-tools
from an elevated PowerShell or CMD.exe (run as Administrator).
Using the npm install --global --production windows-build-tools
on an Elevated prompt works for me. The installer got stuck on visual studio build tools, but they were already installed on my system. So i ctrl +c
the npm install
process and run it once again. This time a messages shows up that the build tools are already installed and the installation will be skipped and continued with python configuration.
Finally the node-sass
installation completed successfully.
BTW node-sass
usage is deprecated and will be removed. The suggestion is to start using sass
.
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