-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.prettierrc.js
40 lines (28 loc) · 1.05 KB
/
.prettierrc.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
/** @type { import('prettier').Options } */
const options = {
// Specify the end of line
endOfLine: "lf",
// use single quotes instead of double quotes
singleQuote: true, // default = false
// Change when properties in objects are quoted.
quoteProps: "as-needed",
// Use single quotes instead of double quotes in JSX
jsxSingleQuote: false,
// Put the > of a multi-line JSX element at the end of the last line instead of being alone on the next line.
jsxBracketSameLine: true, // false
// Print trailing commas wherever possible when multi-line
trailingComma: "es5",
// Fit code within this line limit
printWidth: 80,
// Specify the number of spaces per indentation-level
tabWidth: 2,
// Indent lines with tabs instead of spaces.
useTabs: false,
// semicolons at the ends of statements
semi: true,
// Controls the printing of spaces inside object literals
bracketSpacing: true,
// Include parentheses around a sole arrow function parameter
arrowParens: "avoid", // default = 'always'
};
module.exports = options;