-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtailwind.config.js
57 lines (55 loc) · 1.56 KB
/
tailwind.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
// tailwind.config.js
const isProduction = !process.env.ROLLUP_WATCH; // or some other env var like NODE_ENV
module.exports = {
theme: {
extend: {
animation: {
example: 'example 0.8s infinite',
'spin-slow': 'spin 3s linear infinite',
wiggle: 'wiggle 1s ease-in-out infinite',
},
keyframes: {
example: {
'0%, 25%': {
"background-color": "gray"
},
'20%': {
"background-color": "black"
}
},
wiggle: {
'0%, 100%': { transform: 'rotate(-3deg)' },
'50%': { transform: 'rotate(3deg)' },
}
}
}
},
// only needed in Tailwind 1.0 for tailwind 2.0 compat
// future: {
// purgeLayersByDefault: true,
// removeDeprecatedGapUtilities: true,
// },
darkMode: 'class',
plugins: [
// for tailwind UI users only
// require('@tailwindcss/ui'),
// other plugins here
],
mode: 'jit',
purge: {
content: [
"./src/**/*.svelte",
// may also want to include HTML files
// "./src/**/*.html"
],
// this is for extracting Svelte `class:` syntax but is not perfect yet, see below
// defaultExtractor: content => {
// const broadMatches = content.match(/[^<>"'`\s]*[^<>"'`\s:]/g) || []
// const broadMatchesWithoutTrailingSlash = broadMatches.map(match => _.trimEnd(match, '\\'))
// const matches = broadMatches
// .concat(broadMatchesWithoutTrailingSlash)
// return matches
// },
enabled: isProduction // disable purge in dev
},
};