1. 安装依赖
    

npm install node-sass --save
npm install sass-loader --save

 

2. 配置, 若项目的根目录中没有webpack.config.js 文件, 就在根目录新建即可

module.exports = {
  lintOnSave: false,
  plugins: {
    'autoprefixer': {
      browsers: ['Android >= 4.0', 'iOS >= 7']
    },
    'postcss-pxtorem': {
      rootValue: 37.5,
      propList: ['*']
    }
  }
}

  

相关文章:

  • 2021-12-20
  • 2022-12-23
  • 2021-04-11
  • 2021-05-22
  • 2021-07-13
  • 2022-12-23
  • 2022-12-23
  • 2021-09-19
猜你喜欢
  • 2021-05-08
  • 2022-12-23
  • 2021-05-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-27
相关资源
相似解决方案