webpack less Unexpected character '@' (1:0)

rules: [
{
test: /\.(sa|sc|c)ss$/,
use: [
devMode ? "style-loader" : MiniCssExtractPlugin.loader,
"css-loader",
"less-loader",
"sass-loader",
],
},]

  

 
改为 (增加正则匹配)
 
rules: [
{
test: /\.(le|sa|sc|c)ss$/,
use: [
devMode ? "style-loader" : MiniCssExtractPlugin.loader,
"css-loader",
"less-loader",
"sass-loader",
],
},

  

posted @ 2020-10-29 16:55  winyh  阅读(425)  评论(0编辑  收藏  举报