forked from zen-browser/www
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprettier.config.js
More file actions
58 lines (54 loc) · 1.02 KB
/
prettier.config.js
File metadata and controls
58 lines (54 loc) · 1.02 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
54
55
56
57
58
/**
* @type {import('prettier').Config}
*/
export default {
// Basic formatting
printWidth: 100,
tabWidth: 2,
useTabs: false,
semi: false,
singleQuote: true,
quoteProps: 'as-needed',
trailingComma: 'es5',
bracketSpacing: true,
bracketSameLine: false,
arrowParens: 'avoid',
// Language-specific formatting
overrides: [
{
files: '*.astro',
options: {
parser: 'astro',
},
},
{
files: ['*.json', '*.jsonc'],
options: {
trailingComma: 'none',
singleQuote: false,
},
},
{
files: ['*.md', '*.mdx'],
options: {
printWidth: 80,
proseWrap: 'never',
},
},
{
files: ['*.yml', '*.yaml'],
options: {
singleQuote: false,
},
},
],
// Plugins
plugins: [
'prettier-plugin-astro',
'prettier-plugin-tailwindcss', // Must be last
],
// Plugin-specific options
tailwindFunctions: ['clsx', 'cn', 'twMerge'],
// Astro-specific options
astroAllowShorthand: false,
}