输入以下两个命令:
代码语言:javascript复制npm uninstall node-sass
npm i -D sass
注:Mac环境如果进行了系统升级,需要重新安装Xcode,执行命令
代码语言:javascript复制xcode-select install
不然会出现如下的错误
Mac 解决 gyp: No Xcode or CLT version detected! 报错
如果出现python2的错误
代码语言:javascript复制gyp verb `which` failed Error: not found: python2
去官网下载安装python2.7的包即可;
关联错误:
代码语言:javascript复制Node Sass does not yet support your current environment: OS X 64-bit with Unsupported runtime (93)