-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathtslint.json
228 lines (228 loc) · 9.13 KB
/
tslint.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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
{
// Started from v5.1.0,
"extends": [
"tslint:latest"
],
"rules" : {
"adjacent-overload-signatures" : true,
"ban-types" : [false, ["Object", "Use {} instead."], ["String"]],
"member-access" : [false, "check-accessor", "check-constructor"],
"member-ordering" : false,
"no-any" : false,
"no-empty-interface" : false,
"no-import-side-effect" : [true, {"ignore-module": "(\\.css|\\.sass|\\.scss)$"}],
"no-inferrable-types" : [false, "ignore-params"],
"no-internal-module" : true,
"no-magic-numbers" : [false, {"allowed-numbers": [0, 1], "ignore-jsx": true}],
"no-namespace" : false,
"no-non-null-assertion" : false,
"no-reference" : true,
"no-var-requires" : false,
"only-arrow-functions" : [true, "allow-declarations", "allow-named-functions"],
"prefer-for-of" : true,
"typedef" : [
false,
"call-signature",
"arrow-call-signature",
"parameter",
"arrow-parameter",
"property-declaration",
"variable-declaration",
"member-variable-declaration",
"object-destructuring",
"array-destructuring"
],
"typedef-whitespace" : [
true,
{
"call-signature" : "nospace",
"index-signature" : "nospace",
"parameter" : "nospace",
"property-declaration": "nospace",
"variable-declaration": "nospace"
},
{
"call-signature" : "onespace",
"index-signature" : "onespace",
"parameter" : "onespace",
"property-declaration": "onespace",
"variable-declaration": "onespace"
}
],
"unified-signatures" : true,
"ban" : [
true,
"alert",
["window", "alert"],
"confirm",
["window", "confirm"],
["_", "isNil"]
],
"curly" : true,
"forin" : true,
"import-blacklist" : false,
"label-position" : true,
"no-arg" : true,
"no-bitwise" : false,
"no-conditional-assignment" : true,
"no-console" : [true, "log", "warn", "debug"],
"no-construct" : true,
"no-debugger" : true,
"no-duplicate-super" : true,
"no-duplicate-variable" : true,
"no-empty" : true,
"no-eval" : true,
"no-invalid-template-strings" : true,
"no-invalid-this" : [true, "check-function-in-method"],
"no-misused-new" : true,
"no-null-keyword" : false,
"no-shadowed-variable" : [true, {"underscore": true}],
"no-sparse-arrays" : true,
"no-string-literal" : false,
"no-string-throw" : true,
"no-switch-case-fall-through" : true,
"no-unsafe-finally" : true,
"no-unused-expression" : [true, "allow-new"],
// Deprecated in v5.11.0
//"no-unused-variable" : [true],
// Deprecated in v5.17.0
//"no-use-before-declare" : true,
"no-var-keyword" : true,
"radix" : true,
"switch-default" : true,
"triple-equals" : [true, "allow-null-check"],
// Deprecated in v5.8.0
//"typeof-compare" : true,
"use-isnan" : true,
"cyclomatic-complexity" : [true, 20],
"eofline" : true,
"indent" : [true, "spaces"],
"linebreak-style" : false,
"max-classes-per-file" : [false, 1],
"max-file-line-count" : false,
"max-line-length" : false,
"no-default-export" : false,
"no-mergeable-namespace" : true,
"no-require-imports" : false,
"object-literal-sort-keys" : [false, "match-declaration-order-only", "shorthand-first"],
"prefer-const" : true,
"trailing-comma" : [true, {"multiline": "always", "singleline": "never"}],
"align" : false,
"array-type" : [true, "array"],
"arrow-parens" : [true, "ban-single-arg-parens"],
"arrow-return-shorthand" : [true, "multiline"],
"callable-types" : false,
"class-name" : true,
"comment-format" : false,
"completed-docs" : [
false,
"classes",
"enums",
"functions",
"interfaces",
"methods",
"namespaces",
"properties",
"types",
"variables"
],
"file-header" : false,
"import-spacing" : false,
"interface-name" : [false, "always-prefix"],
"interface-over-type-literal" : true,
"jsdoc-format" : true,
"newline-before-return" : false,
"new-parens" : true,
"no-angle-bracket-type-assertion" : true,
"no-consecutive-blank-lines" : [true, 2],
"no-parameter-properties" : false,
"no-reference-import" : true,
"no-trailing-whitespace" : true,
"no-unnecessary-callback-wrapper" : true,
"no-unnecessary-initializer" : true,
"object-literal-key-quotes" : [true, "consistent-as-needed"],
"object-literal-shorthand" : true,
"one-line" : [
true,
"check-catch",
"check-finally",
"check-else",
"check-open-brace",
"check-whitespace"
],
"one-variable-per-declaration" : [true, "ignore-for-loop"],
"ordered-imports" : false,
"prefer-function-over-method" : false,
"prefer-method-signature" : true,
"prefer-template" : true,
"quotemark" : [true, "single", "avoid-escape", "jsx-double"],
"semicolon" : [true, "always"],
"space-before-function-paren" : [true, "never"],
"variable-name" : [false, "check-format", "allow-leading-underscore"],
"whitespace" : [
true,
"check-branch",
"check-decl",
"check-operator",
"check-module",
"check-separator",
"check-type",
"check-typecast",
"check-preblock"
],
// v5.2.0 Updates
"no-object-literal-type-assertion": [true, {"allow-arguments": true}],
"no-irregular-whitespace" : true,
"prefer-switch" : [true, {"min-cases": 3}],
"number-literal-format" : true,
"deprecation" : true,
"no-unnecessary-type-assertion" : false,
// v5.3.0 Updates
"prefer-object-spread" : true,
"encoding" : true,
"prefer-conditional-expression" : false,
// v5.4.0 Updates
"switch-final-break" : true,
"use-default-type-parameter" : false,
"binary-expression-operand-order" : false,
// v5.5.0 Updates
"no-this-assignment" : true,
// v5.6.0 Updates
"no-duplicate-imports" : [true, {"allow-namespace-imports": true}],
"no-submodule-imports" : false,
"space-within-parens" : false,
// v5.7.0 Updates
"no-parameter-reassignment" : true,
// v5.8.0 Updates
"no-return-await" : true,
"no-redundant-jsdoc" : false,
"no-duplicate-switch-case" : true,
"no-implicit-dependencies" : true,
"no-unnecessary-class" : true,
"ban-comma-operator" : true,
// v5.9.0 Updates
"no-dynamic-delete" : true,
"prefer-readonly" : [true /*, "only-inline-lambdas"*/],
"newline-per-chained-call" : false,
// v5.10.0 Updates
"prefer-while" : true,
// v5.11.0 Updates
"file-name-casing" : [false, {".tsx": "pascal-case", ".ts": "kebab-case"}],
// v5.12.0 Updates
"type-literal-delimiter" : false,
"ban-ts-ignore" : true,
"function-constructor" : true,
"increment-decrement" : [true, "allow-post"],
"no-default-import" : false,
"unnecessary-constructor" : true,
"comment-type" : false,
// v5.13.0 Updates
"no-restricted-globals" : [false],
// v5.14.0 Updates
"static-this" : true,
"unnecessary-else" : [true, {"allow-else-if": false}],
"no-tautology-expression" : true,
// v5.15.0 Updates
"no-null-undefined-union" : false
}
}