[email protected] install /home/user/Documents/project/node_modules/node-sass
> node scripts/install.js
WARN invalid config loglevel="notice"
Can not download file from https://raw.githubusercontent.com/sass/node-sass-binaries/v2.1.1/linux-x64-node-8.2/binding.node
> [email protected] postinstall /home/user/Documents/project/node_modules/node-sass
> node scripts/build.js
module.js:487
throw err;
^
Error: Cannot find module '/home/user/Documents/project/node_modules/node-sass/node_modules/pangyp/bin/node-gyp'
at Function.Module._resolveFilename (module.js:485:15)
at Function.Module._load (module.js:437:25)
at Function.Module.runMain (module.js:605:10)
at startup (bootstrap_node.js:158:16)
at bootstrap_node.js:575:3
Build failed
added 2186 packages in 42.166s
I tried so far:
To make node-sass available in your source code, npm needs to build the package and create a binding for your environment. When you change the version of Node.js used on your project, then the binding needs to be rebuild so that node-sass can be imported and executed from your code.
npm ERR! gyp ERR! System Windows_NT 10.0.19041 npm ERR! Build failed with error code: 1 npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\Solomon Iseh\AppData\Local pm-cache_logs\2021-04-20T13_48_12_336Z-debug.log
Learn why you need to constantly rebuild node-sass to make it work The node-sass package is a library that provides binding for Node.js to LibSass, which is the Sass processsor written in C++. When running a project that has a dependency on node-sass, you may see an error that says you need to run npm rebuild node-sass as shown below:
It will list down all your installed node versions in console by using "nvm llist" command and you can switch to your specified node version when needed by this command "nvm use NODE_VERSION" Sorry, something went wrong. Sorry, something went wrong. hmm getting this though on the right version of node; something to do with yarn; npm is fine
You're ready to go! :)
node-sass has minimum dependency according to the version of node installed in your system. You can find out the minimum version required here
by using yarn run:
yarn add node-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