forked from core-ds/core-components
-
Notifications
You must be signed in to change notification settings - Fork 0
/
postcss.config.js
31 lines (29 loc) · 967 Bytes
/
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
/* eslint-disable @typescript-eslint/no-var-requires */
/* eslint-disable global-require */
const path = require('path');
module.exports = {
plugins: [
require('postcss-import')({}),
require('postcss-mixins')({
mixinsDir: path.join(__dirname, 'packages/vars/src'),
}),
require('postcss-preset-env')({
stage: 3,
features: {
'nesting-rules': true,
'color-mod-function': { unresolved: 'ignore' },
'custom-properties': false,
},
}),
require('postcss-for')({}),
require('postcss-each')({}),
require('postcss-custom-media')({
importFrom: {
customMedia: require('./packages/mq/src/mq.json'),
},
}),
...(process.env.BUILD_WITHOUT_CSS_VARS === 'true'
? [require('postcss-custom-properties')({ preserve: false })]
: []),
],
};