I'm trying to do npm install
and an error appears :
Failed at the [email protected] postinstall script.
I tried to delete node_modules
and then reinstall it, same error appears.
what will be the solution?
node v8.9.3
npm v5.4.2
ionic 3.19.0
Got the same problem (node v10.3.0, ionic 3.13.0). This worked :
package-
lock.json
,node_modules
folder, npm install
again.try
sudo rm -rf package-lock.json node_modules
sudo npm cache clean --force
npm i --unsafe-perm node-sass
Just Try with this command hope it will very helpful. it's working for me
sudo npm install -g [email protected] --unsafe-perm=true --allow-root
rolling back to node v10.17.0
fixed the problem to me.
You can use nvm to do so:
https://github.com/nvm-sh/nvm
> nvm install 10.17.0
> nvm use 10.17.0
> node -v
10.17.0
I also had to face the same problem with node v12.16.3
.
Remove node-sass
dependency from your package.json
if it is mentioned in your dependencies
.This will allow npm to install other required dependencies without any disruption.
Delete package-lock.json
file and node_modules
folder from your project.
Force clean the entire NPM cache by using following comand.
npm cache clean --force
Re-Install all the dependencies.
npm install
Now you can install node-sass
.
npm i node-sass
[email protected] cannot be installed on node 8
Please update either node-sass or node version compatible
Go to https://github.com/sass/node-sass/releases to check which fits for you
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