-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdprint.json
50 lines (50 loc) · 2.03 KB
/
dprint.json
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
{
"typescript": {
"indentWidth": 2, // default setting
"lineWidth": 120, // default setting
"useTabs": false, // default setting
"semiColons": "always", // default setting
"quoteStyle": "preferSingle", // default setting
"bracePosition": "sameLine", // same line for if{} (default)
"useBraces": "always", // dont allow single line if without braces
"quoteProps": "consistent", // if all props dont need quotes okay to omit
"nextControlFlowPosition": "nextLine", // newline for else
"trailingCommas": "onlyMultiLine", // only use trailing commas if content is multiline
"operatorPosition": "nextLine", // operator position on next line
"preferHanging": false, // dont use indented content when line width exceeded
"arrowFunction.useParentheses": "maintain", // self explanatory
"module.sortImportDeclarations": "caseInsensitive",
"module.sortExportDeclarations": "caseInsensitive",
"spaceAround": false, // myFunction(true) vs myFunction( true )
"spaceSurroundingProperties": true, // { one: 'two' } vs {one: 'two'}
"importDeclaration.spaceSurroundingNamedImports": true,
"exportDeclaration.spaceSurroundingNamedExports": true,
"importDeclaration.preferSingleLine": true,
"exportDeclaration.preferSingleLine": true,
"importDeclaration.sortNamedImports": "caseInsensitive",
"exportDeclaration.sortNamedExports": "caseInsensitive",
"forInStatement.spaceAfterForKeyword": false, // for(const prop of props)
"ifStatement.spaceAfterIfKeyword": false, // if(foo) vs if (foo)
"whileStatement.spaceAfterWhileKeyword": false
},
"json": {},
"markdown": {},
"toml": {},
"excludes": [
"dev/",
"dist/",
"tests/",
"LICENSE.md",
"README.md",
"**/*.html",
"**/*.md",
"**/node_modules",
"**/*-lock.json"
],
"plugins": [
"https://plugins.dprint.dev/typescript-0.89.0.wasm",
"https://plugins.dprint.dev/json-0.19.1.wasm",
"https://plugins.dprint.dev/markdown-0.16.3.wasm",
"https://plugins.dprint.dev/toml-0.6.0.wasm"
]
}