README
wtt-sass
配置(当前是基于 vue-cli3 引入),vue.config.js
- 引入
let includePaths = require('wtt-sass').includePaths; // includePaths是wtt-sass中声明的文件的绝对路径
// 拼接上 @import
includePaths = includePaths.map((v, k) => {
return `@import "${v}";`
})
- 配置 sass-loader
// sass-loader 插件的 option 中增加如下字段:
sass:{
data: `${includePaths.join('')}`
}