-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpostcss.config.js
40 lines (39 loc) · 1.12 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
import postcssPresetEnv from 'postcss-preset-env';
import { purgeCSSPlugin } from '@fullhuman/postcss-purgecss';
import calcPlugin from 'postcss-calc';
import autoprefixer from 'autoprefixer';
export default {
plugins: [
postcssPresetEnv(),
calcPlugin(),
purgeCSSPlugin({
content: ['./hugo_stats.json'],
safelist: [
'success',
'error',
'rotate-0',
'rotate-1',
'rotate-2',
'rotate-3',
'isobg',
'iso',
'iso-face',
'iso-left',
'iso-right',
'iso-top',
'iso-bottom',
'iso-back-left',
'iso-back-right',
],
defaultExtractor: (content) => {
const els = JSON.parse(content).htmlElements;
return [
...(els.tags || []),
...(els.classes || []),
...(els.ids || []),
];
},
}),
autoprefixer(),
],
};