Repository navigation
Expand file tree
/
Copy pathpostcss.config.js
More file actions
53 lines (52 loc) · 1.49 KB
/
Copy pathpostcss.config.js
File metadata and controls
53 lines (52 loc) · 1.49 KB
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
50
51
52
53
import purgecss from '@fullhuman/postcss-purgecss';
import tailwindcss from '@tailwindcss/postcss';
export default {
plugins: [
tailwindcss(),
process.env.NODE_ENV === 'production'
? purgecss({
content: [
'./index.html',
'./src/**/*.{js,jsx,ts,tsx,html}'
],
defaultExtractor: (content) => content.match(/[\w-/:]+(?<!:)/g) || [],
safelist: {
standard: [
/^leaflet-/,
/^react-datepicker/,
/^recharts/,
'leaflet-container',
'leaflet-zoom-animated',
'leaflet-interactive',
'leaflet-pane',
'leaflet-map-pane',
'leaflet-tile-pane',
'leaflet-overlay-pane',
'leaflet-shadow-pane',
'leaflet-marker-pane',
'leaflet-tooltip-pane',
'leaflet-popup-pane',
'leaflet-tile',
'leaflet-tile-loaded',
'leaflet-layer',
'leaflet-marker-icon',
'leaflet-marker-shadow',
'leaflet-control-zoom',
'leaflet-control',
'leaflet-bar',
'loading-spinner',
'live-dot',
'active',
'dark',
'light',
],
deep: [
/^leaflet-/,
/^react-datepicker/,
/^recharts/
]
}
})
: null
].filter(Boolean)
};