-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpostcss.config.mjs
49 lines (44 loc) · 1.22 KB
/
postcss.config.mjs
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
45
46
47
48
49
import postcssImport from 'postcss-import';
import postcssGlobalDataPlugin from '@csstools/postcss-global-data';
import postcssPresetEnvPlugin from 'postcss-preset-env';
import postcssSortMediaQueries from 'postcss-sort-media-queries';
import postcssCombineSelectors from 'postcss-combine-duplicated-selectors';
import postcssPixelToRemPlugin from 'postcss-pxtorem';
import postcssCalc from 'postcss-calc';
import postcssHexrgba from 'postcss-hexrgba';
import postcssReporterPlugin from 'postcss-reporter';
const postcssGlobalData = postcssGlobalDataPlugin({
files: ['src/assets/css/_base/settings.css'],
});
const postcssPresetEnv = postcssPresetEnvPlugin({
stage: 1,
autoprefixer: {
grid: 'autoplace',
},
features: {
'nesting-rules': true,
'custom-properties': {
disableDeprecationNotice: true,
},
'has-pseudo-class': true,
},
});
const pxtorem = postcssPixelToRemPlugin({
replace: false,
});
const postcssReporter = postcssReporterPlugin({
positionless: 'last',
});
export default {
plugins: [
postcssImport,
postcssGlobalData,
postcssPresetEnv,
postcssSortMediaQueries,
postcssCombineSelectors,
pxtorem,
postcssCalc,
postcssHexrgba,
postcssReporter,
],
};