-
Notifications
You must be signed in to change notification settings - Fork 70
/
Copy pathtailwind.config.cjs
48 lines (47 loc) · 1.43 KB
/
tailwind.config.cjs
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
const { tailwindExtractor } = require("tailwindcss/lib/lib/purgeUnusedStyles");
const { fontFamily } = require("tailwindcss/defaultTheme");
const colors = require("tailwindcss/colors");
module.exports = {
mode: "aot",
purge: {
content: ["./src/**/*.{html,js,svelte,ts}"],
options: {
defaultExtractor: (content) => [
// If this stops working, please open an issue at https://github.com/svelte-add/tailwindcss/issues rather than bothering Tailwind Labs about it
...tailwindExtractor(content),
// Match Svelte class: directives (https://github.com/tailwindlabs/tailwindcss/discussions/1731)
...[...content.matchAll(/(?:class:)*([\w\d-/:%.]+)/gm)].map(
([_match, group, ..._rest]) => group,
),
],
},
safelist: [/^svelte-[\d\w]+$/],
},
theme: {
extend: {
fontFamily: {
sans: ["Inter", ...fontFamily.sans],
serif: [...fontFamily.serif],
mono: ["Fira Mono", ...fontFamily.mono],
},
colors: {
transparent: "transparent",
current: "currentColor",
black: colors.black,
white: colors.white,
gray: colors.trueGray,
"cool-gray": colors.blueGray,
blue: colors.blue,
indigo: colors.indigo,
red: colors.rose,
orange: colors.orange,
yellow: colors.amber,
pink: colors.pink,
},
},
},
variants: {
extend: {},
},
plugins: [],
};