-
Notifications
You must be signed in to change notification settings - Fork 3
/
postcss.config.js
42 lines (40 loc) · 1 KB
/
postcss.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
const autoprefixer = require('autoprefixer');
const precss = require('precss');
const postCssNested = require('postcss-nested');
const postCssApply = require('postcss-apply');
const postCssVariables = require('postcss-css-variables');
const postCssImport = require('postcss-import');
const postCssMath = require('postcss-math');
const postCssExtend = require('postcss-extend');
const cssNano = require('cssnano');
const DEBUG = process.env.NODE_ENV !== 'production';
module.exports = {
plugins: [
postCssImport({
path: [
'assets/styles',
],
}),
precss,
postCssNested,
postCssVariables,
postCssMath,
postCssApply,
postCssExtend,
autoprefixer,
].concat(DEBUG ? [] : [
cssNano({
autoprefixer: false,
reduceInitial: false,
discardComments: {
removeAll: true,
},
discardEmpty: true,
discardUnused: false,
mergeIdents: false,
normalizeUrl: false,
reduceIdents: false,
zindex: false,
}),
]),
};