Node Sass version 7.0.0 is incompatible with ^4.0.0 || ^5.0.0 || ^6.0
I have a react project I created using create-react-app
And I was trying to use sass in react by installing node-sass
for react.js
But I keep getting an error saying It's incompatible.
Node Sass version 7.0.0 is incompatible with ^4.0.0 || ^5.0.0 || ^6.0.0
Node Sass version 7.0.0 is incompatible with ^4.0.0 || ^5.0.0 || ^6.0.0
What is the problem?
Solution 1:
Dont use node-sass
anymore
node-sass
is depricated, And the new version is sass
You can uninstall the old node-sass
using
npm uninstall node-sass
And install sass
directly
npm install sass
Then it works !
But if you for some reason choose to keep using node-sass
You can use the following table to install the appropriate version of node-sass
for your installed node version which you can check by the command node --version
npm install [email protected]
You change 6.0 based on the table
I hope this is helpful