步骤1

1
2
npm install node-sass --save-dev
npm install sass-loader --save-dev

步骤2

打开webpack.base.config.js在loaders里面加上

1
2
3
4
{
   test: /\.scss$/,
   loaders: ["style", "css", "sass"]
 }

步骤3

在需要用到scss的地方写上:

1
<style lang="scss" scoped="" type="text/css"></style>

相关文章:

  • 2021-08-13
  • 2021-11-30
  • 2022-12-23
  • 2021-07-27
  • 2021-09-07
  • 2021-06-26
  • 2021-11-01
猜你喜欢
  • 2022-12-23
  • 2021-05-24
  • 2022-03-07
  • 2021-11-15
  • 2021-06-11
相关资源
相似解决方案