This repository has been archived by the owner on Jun 27, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
97 lines (97 loc) · 2.84 KB
/
.eslintrc.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
{
"env": {
"commonjs": true,
"es6": true,
"node": true
},
"extends": ["eslint:recommended", "prettier", "plugin:prettier/recommended", "plugin:@typescript-eslint/recommended", "plugin:@typescript-eslint/eslint-recommended"],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 2021,
"sourceType": "module",
"ecmaFeatures": {
"modules": true
}
},
"plugins": ["@typescript-eslint"],
"rules": {
"prettier/prettier": "warn",
"no-cond-assign": [2, "except-parens"],
"no-unused-vars": 0,
"@typescript-eslint/no-unused-vars": 1,
"no-empty": [
"error",
{
"allowEmptyCatch": true
}
],
"prefer-const": [
"warn",
{
"destructuring": "all"
}
],
"spaced-comment": "warn",
"linebreak-style": ["error", "windows"],
"indent": ["error", 4],
"curly": ["error", "multi"],
"quotes": ["error", "single"],
"semi": ["error", "always"],
"eol-last": ["error", "always"],
"no-trailing-spaces": "error",
"sort-imports": [
"error",
{
"memberSyntaxSortOrder": ["none", "single", "all", "multiple"],
"ignoreDeclarationSort": true
}
],
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/no-non-null-assertion": ["off"],
"@typescript-eslint/array-type": [
"error",
{
"default": "array",
"readonly": "array"
}
],
"@typescript-eslint/ban-types": [
"error",
{
"types": {
"Array": "Do not use Array.",
"Object": "Do not use Object.",
"String": "Do not use String."
}
}
],
"@typescript-eslint/consistent-type-definitions": ["error", "interface"],
"@typescript-eslint/consistent-type-assertions": [
"error",
{
"assertionStyle": "as",
"objectLiteralTypeAssertions": "allow"
}
],
"@typescript-eslint/explicit-function-return-type": [
"error",
{
"allowExpressions": true
}
]
},
"overrides": [
{
"files": ["test/**/*.ts"],
"globals": {
"describe": true,
"it": true,
"beforeEach": true
}
}
]
}