@@ -6,19 +6,18 @@ export = {
6
6
{
7
7
files : [ '*.ts' , '*.tsx' ] ,
8
8
rules : {
9
- camelcase : 'off' , // in favor of TypeScript rule
9
+ // TypeScript has this functionality by default:
10
+ 'no-undef' : 'off' ,
11
+
12
+ // Rules replaced by @typescript -eslint versions:
13
+ camelcase : 'off' ,
10
14
indent : 'off' ,
11
15
'no-array-constructor' : 'off' ,
12
- 'no-undef' : 'off' , // TypeScript has this functionality by default
13
- 'no-unused-vars' : 'off' , // in favor of TypeScript rule
16
+ 'no-unused-vars' : 'off' ,
14
17
'no-useless-constructor' : 'off' ,
15
- '@typescript-eslint/adjacent-overload-signatures' : 'error' ,
16
- ' @typescript-eslint/array-type' : [ 'error' , 'array-simple' ] ,
18
+
19
+ // @typescript -eslint versions of Standard.js rules:
17
20
'@typescript-eslint/camelcase' : [ 'error' , { properties : 'never' } ] ,
18
- '@typescript-eslint/explicit-function-return-type' : [ 'error' , {
19
- allowHigherOrderFunctions : true
20
- } ] ,
21
- '@typescript-eslint/explicit-member-accessibility' : 'error' ,
22
21
'@typescript-eslint/indent' : [ 'error' , 2 , {
23
22
SwitchCase : 1 ,
24
23
VariableDeclarator : 1 ,
@@ -33,6 +32,18 @@ export = {
33
32
flatTernaryExpressions : false ,
34
33
ignoreComments : false
35
34
} ] ,
35
+ '@typescript-eslint/no-array-constructor' : 'error' ,
36
+ '@typescript-eslint/no-unused-vars' : [ 'error' , { args : 'none' } ] ,
37
+ '@typescript-eslint/no-use-before-define' : [ 'error' , { functions : false , classes : false , variables : false , typedefs : false } ] ,
38
+ '@typescript-eslint/no-useless-constructor' : 'error' ,
39
+
40
+ // New Typescript-only rules:
41
+ '@typescript-eslint/adjacent-overload-signatures' : 'error' ,
42
+ '@typescript-eslint/array-type' : [ 'error' , 'array-simple' ] ,
43
+ '@typescript-eslint/explicit-function-return-type' : [ 'error' , {
44
+ allowHigherOrderFunctions : true
45
+ } ] ,
46
+ '@typescript-eslint/explicit-member-accessibility' : 'error' ,
36
47
'@typescript-eslint/member-delimiter-style' : [
37
48
'error' ,
38
49
{
@@ -41,7 +52,6 @@ export = {
41
52
}
42
53
] ,
43
54
'@typescript-eslint/no-angle-bracket-type-assertion' : 'error' ,
44
- '@typescript-eslint/no-array-constructor' : 'error' ,
45
55
'@typescript-eslint/no-empty-interface' : 'error' ,
46
56
'@typescript-eslint/no-extraneous-class' : 'error' ,
47
57
'@typescript-eslint/no-for-in-array' : 'error' ,
@@ -52,15 +62,12 @@ export = {
52
62
'@typescript-eslint/no-this-alias' : [ 'error' , { allowDestructuring : true } ] ,
53
63
'@typescript-eslint/no-triple-slash-reference' : 'error' ,
54
64
'@typescript-eslint/no-unnecessary-type-assertion' : 'error' ,
55
- '@typescript-eslint/no-unused-vars' : [ 'error' , { args : 'none' } ] ,
56
- '@typescript-eslint/no-use-before-define' : [ 'error' , { functions : false , classes : false , variables : false , typedefs : false } ] ,
57
- '@typescript-eslint/no-useless-constructor' : 'error' ,
58
65
'@typescript-eslint/no-var-requires' : 'error' ,
59
66
'@typescript-eslint/prefer-function-type' : 'error' ,
60
67
'@typescript-eslint/prefer-interface' : 'error' ,
61
68
'@typescript-eslint/promise-function-async' : 'error' ,
62
- '@typescript-eslint/restrict-plus-operands' : 'error' ,
63
69
'@typescript-eslint/require-array-sort-compare' : 'error' ,
70
+ '@typescript-eslint/restrict-plus-operands' : 'error' ,
64
71
'@typescript-eslint/type-annotation-spacing' : 'error'
65
72
}
66
73
}
0 commit comments