-
Notifications
You must be signed in to change notification settings - Fork 1
/
webpack.build.config.js
44 lines (44 loc) · 1.33 KB
/
webpack.build.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
const cssnano = require('cssnano')
const pxtorem = require('postcss-pxtorem')
module.exports = {
module: {
rules: [{
test: /\.vue$/,
loader: 'vue-loader',
options: {
extractCSS: false,
preserveWhitespace: false,
transformToRequire: {
video: 'src',
source: 'src',
img: 'src',
image: 'xlink:href'
},
postcss: [
require('autoprefixer')({
browsers: ['iOS >= 7', 'Android >= 4.0']
}),
// pxtorem({
// rootValue: 100,
// propWhiteList: [],
// }),
cssnano({
zindex: false,
reduceIdents: false,
// safe: true
})
]
}
},
{
test: /\.js$/,
loader: 'babel-loader',
exclude: /node_modules/
}
]
},
optimization: {
minimize: true
},
mode: 'production',
}