报错1:The "path" argument must be of type string. Received type undefined
安装好scss后,使用时报错:The "path" argument must be of type string. Received type undefined
后来查看是版本问题,将 “sass-loader”:"^10.0.1"版本,修改为 “sass-loader”: “^7.3.1”版本,
卸载10.0版本,下载7.3版本,只需执行:
npm uninstall sass-loader
npm install sass-loader@7 --save-dev
即可正常运行。
报错2:Node Sass version 5.0.0 is incompatible with ^4.0.0.
node-sass版本问题,下载node-sass4.0版本,执行:
npm uninstall node-sass //卸载 node-sass
npm install node-sass@4 //安装5.0之前版本
网友评论