在windows下安装node-sass失败,提示\node-sass: Command failed,解决方案

 

使用yarn暗转时,报如上错误,可能原因:

1.没有安装python,先执行:

npm install -g node-gyp   (编译环境)

npm install --global --production windows-build-tools

2.如果依然报错,如下执行:

npm install -g mirror-config-china --registry=http://registry.npm.taobao.org
npm install node-sass
yarn install

posted @ 2020-12-11 13:45  xiyunfang  阅读(6653)  评论(0)    收藏  举报