`libsass` bindings not found. Try reinstalling `node-sass`?

本篇文章由:http://xinpure.com/libsass-bindings-not-found-try-reinstalling-node-sass/

坑一记

`libsass` bindings not found. Try reinstalling `node-sass`?

这个错误提示看似简单,确是个坑。。。

正常来说,按提示操作即可解决问题,所以:

npm uninstall node-sass

然后:

npm install node-sass

如此就是所谓的 reinstall 吧,然而并没有什么卵用!

再重装 node-sass 之后,错误提示依旧,瞬间就懵了(内心是崩溃的)。。。

---- 一个劲的 百度 Google 之后 ----

解决方法其实也不难,就是:

rm -rf node_modules

npm install

是的,没错,就是删除当前目录下的 node_modules 目录,然后重新安装所有依赖模块

好吧,其实还是没搞清楚错误的原因(猜测是模块之间的依赖关系问题),但至少解决了问题不是吗

记一笔~

参考链接: http://forum.ionicframework.com/t/need-help-libsass-bindings-not-found-try-reinstalling-node-sass/18368

原文地址:https://www.cnblogs.com/xinpureZhu/p/4898981.html