vue files lang = "scss" error problem

vue files lang = "scss" error problem

New Project .vue file using scss writing style. According to the online tutorial to install centralized dependent module and the following error after configuration:

github URL: Personal blog
An error

This is because we installed sass-loader version is too high, as long as we install the 7.3.1 version of sass-loader problem is solved. If other plug-ins installed: then only need to install version 7.3.1 on the line.

Specific methods are:

  1. Enter the following command:
npm install [email protected] --save-dev //这里安装的是7.3.1版本的sass-loader
npm install node-sass --save
npm install style-loader --save
  1. Add the following code in the module configuration file under the rules (if item generated using vue-cli scaffold, this step is omitted):
{
  test: /\.scss$/,
  loaders: ['style-loader', 'css-loader', 'sass-loader']
}

So that we can use the code lang = "scss" up, and not being given.

Released six original articles · won praise 6 · views 354

Guess you like

Origin blog.csdn.net/qq_42586895/article/details/102921787