@@ -4,115 +4,72 @@ module.exports = {
4
4
es6 : true ,
5
5
node : true ,
6
6
} ,
7
- ignorePatterns : [ 'node_modules' ] ,
7
+ ignorePatterns : [ 'node_modules' , '**/__mocks__*' , '**/__tests__*' , '**/*.spec.*' ] ,
8
8
parser : '@typescript-eslint/parser' ,
9
9
parserOptions : {
10
10
project : 'tsconfig.json' ,
11
11
sourceType : 'module' ,
12
12
} ,
13
- plugins : [ '@typescript-eslint' ] ,
14
- extends : [ 'prettier' , 'prettier/react' ] ,
13
+ plugins : [ 'react' , 'prettier' , '@typescript-eslint' ] ,
14
+ extends : [
15
+ 'eslint:recommended' ,
16
+ 'plugin:react/recommended' ,
17
+ 'airbnb-typescript' ,
18
+ 'plugin:@typescript-eslint/eslint-recommended' ,
19
+ 'plugin:@typescript-eslint/recommended' ,
20
+ 'plugin:@typescript-eslint/recommended-requiring-type-checking' ,
21
+ 'prettier' ,
22
+ 'plugin:prettier/recommended' ,
23
+ 'prettier/@typescript-eslint' ,
24
+ 'prettier/react' ,
25
+ ] ,
15
26
rules : {
16
- '@typescript-eslint/adjacent-overload-signatures' : 'warn' ,
17
- '@typescript-eslint/array-type' : 'warn' ,
18
- '@typescript-eslint/ban-types' : 'warn' ,
19
- '@typescript-eslint/class-name-casing' : 'warn' ,
20
- '@typescript-eslint/consistent-type-assertions' : 'warn' ,
21
- '@typescript-eslint/indent' : [ 'off' , 2 ] ,
22
- '@typescript-eslint/member-delimiter-style' : [
23
- 'off' ,
24
- {
25
- multiline : {
26
- delimiter : 'none' ,
27
- requireLast : true ,
28
- } ,
29
- singleline : {
30
- delimiter : 'semi' ,
31
- requireLast : false ,
32
- } ,
33
- } ,
34
- ] ,
35
- '@typescript-eslint/member-ordering' : 'off' ,
36
- '@typescript-eslint/no-empty-function' : 'warn' ,
37
- '@typescript-eslint/no-empty-interface' : 'warn' ,
38
- '@typescript-eslint/no-explicit-any' : 'off' ,
39
- '@typescript-eslint/no-misused-new' : 'warn' ,
40
- '@typescript-eslint/no-namespace' : 'warn' ,
41
- '@typescript-eslint/no-parameter-properties' : 'off' ,
42
- '@typescript-eslint/no-this-alias' : 'warn' ,
43
- '@typescript-eslint/no-use-before-define' : 'off' ,
44
- '@typescript-eslint/no-var-requires' : 'warn' ,
45
- '@typescript-eslint/prefer-for-of' : 'warn' ,
46
- '@typescript-eslint/prefer-function-type' : 'warn' ,
47
- '@typescript-eslint/prefer-namespace-keyword' : 'warn' ,
48
- '@typescript-eslint/quotes' : [ 'warn' , 'single' ] ,
49
- '@typescript-eslint/semi' : [ 'off' , null ] ,
50
- '@typescript-eslint/triple-slash-reference' : 'warn' ,
51
- '@typescript-eslint/type-annotation-spacing' : 'off' ,
52
- '@typescript-eslint/unified-signatures' : 'warn' ,
53
- 'arrow-parens' : [ 'off' , 'as-needed' ] ,
54
- camelcase : 'off' ,
55
- 'comma-dangle' : 'off' ,
56
- complexity : 'off' ,
57
- 'constructor-super' : 'warn' ,
58
- 'dot-notation' : 'warn' ,
59
- 'eol-last' : 'off' ,
60
- eqeqeq : [ 'warn' , 'smart' ] ,
61
- 'guard-for-in' : 'warn' ,
62
- 'id-blacklist' : 'off' ,
63
- 'id-match' : 'off' ,
64
- 'import/no-internal-modules' : 'off' ,
65
- 'linebreak-style' : 'off' ,
66
- 'max-classes-per-file' : [ 'warn' , 1 ] ,
67
- 'max-len' : 'off' ,
68
- 'new-parens' : 'off' ,
69
- 'newline-per-chained-call' : 'off' ,
70
- 'no-bitwise' : 'warn' ,
71
- 'no-caller' : 'warn' ,
72
- 'no-cond-assign' : 'warn' ,
73
- 'no-console' : 'warn' ,
74
- 'no-debugger' : 'warn' ,
75
- 'no-duplicate-case' : 'warn' ,
76
- 'no-duplicate-imports' : 'warn' ,
77
- 'no-empty' : 'warn' ,
78
- 'no-eval' : 'warn' ,
79
- 'no-extra-bind' : 'warn' ,
80
- 'no-extra-semi' : 'off' ,
81
- 'no-fallthrough' : 'off' ,
82
- 'no-invalid-this' : 'off' ,
83
- 'no-irregular-whitespace' : 'off' ,
84
- 'no-multiple-empty-lines' : 'off' ,
85
- 'no-new-func' : 'warn' ,
86
- 'no-new-wrappers' : 'warn' ,
87
- 'no-redeclare' : 'warn' ,
88
- 'no-return-await' : 'warn' ,
89
- 'no-sequences' : 'warn' ,
90
- 'no-shadow' : [
91
- 'warn' ,
92
- {
93
- hoist : 'all' ,
94
- } ,
95
- ] ,
96
- 'no-sparse-arrays' : 'warn' ,
97
- 'no-template-curly-in-string' : 'warn' ,
98
- 'no-throw-literal' : 'warn' ,
99
- 'no-trailing-spaces' : 'off' ,
100
- 'no-undef-init' : 'warn' ,
101
- 'no-underscore-dangle' : 'off' ,
102
- 'no-unsafe-finally' : 'warn' ,
103
- 'no-unused-expressions' : 'warn' ,
104
- 'no-unused-labels' : 'warn' ,
105
- 'no-var' : 'warn' ,
106
- 'object-shorthand' : 'warn' ,
107
- 'one-var' : [ 'warn' , 'never' ] ,
108
- 'prefer-const' : 'warn' ,
109
- 'prefer-object-spread' : 'warn' ,
110
- 'quote-props' : 'off' ,
111
- radix : 'warn' ,
112
- 'space-before-function-paren' : 'off' ,
113
- 'space-in-parens' : [ 'off' , 'never' ] ,
114
- 'spaced-comment' : 'warn' ,
115
- 'use-isnan' : 'warn' ,
116
- 'valid-typeof' : 'off' ,
27
+ '@typescript-eslint/interface-name-prefix' : [ 'warn' , { prefixWithI : 'always' } ] ,
28
+ 'import/prefer-default-export' : 'off' ,
29
+ 'react/prop-types' : 'off' ,
30
+ 'react/state-in-constructor' : 'off' ,
31
+ // '@typescript-eslint/adjacent-overload-signatures': 'warn',
32
+ // '@typescript-eslint/array-type': 'warn',
33
+ // '@typescript-eslint/ban-types': 'warn',
34
+ // '@typescript-eslint/class-name-casing': 'warn',
35
+ // '@typescript-eslint/consistent-type-assertions': 'warn',
36
+ // '@typescript-eslint/indent': ['off', 2],
37
+ // '@typescript-eslint/member-delimiter-style': [
38
+ // 'off',
39
+ // {
40
+ // multiline: {
41
+ // delimiter: 'none',
42
+ // requireLast: true,
43
+ // },
44
+ // singleline: {
45
+ // delimiter: 'semi',
46
+ // requireLast: false,
47
+ // },
48
+ // },
49
+ // ],
50
+ // '@typescript-eslint/member-ordering': 'off',
51
+ // '@typescript-eslint/no-empty-function': 'warn',
52
+ // '@typescript-eslint/no-empty-interface': 'warn',
53
+ // '@typescript-eslint/no-explicit-any': 'off',
54
+ // '@typescript-eslint/no-misused-new': 'warn',
55
+ // '@typescript-eslint/no-namespace': 'warn',
56
+ // '@typescript-eslint/no-parameter-properties': 'off',
57
+ // '@typescript-eslint/no-this-alias': 'warn',
58
+ // '@typescript-eslint/no-use-before-define': 'off',
59
+ // '@typescript-eslint/no-var-requires': 'warn',
60
+ // '@typescript-eslint/prefer-for-of': 'warn',
61
+ // '@typescript-eslint/prefer-function-type': 'warn',
62
+ // '@typescript-eslint/prefer-namespace-keyword': 'warn',
63
+ // '@typescript-eslint/quotes': ['warn', 'single'],
64
+ // '@typescript-eslint/semi': ['off', null],
65
+ // '@typescript-eslint/triple-slash-reference': 'warn',
66
+ // '@typescript-eslint/type-annotation-spacing': 'off',
67
+ // '@typescript-eslint/unified-signatures': 'warn',
68
+ // 'arrow-parens': ['off', 'as-needed'],
69
+ } ,
70
+ settings : {
71
+ react : {
72
+ version : 'detect' ,
73
+ } ,
117
74
} ,
118
75
} ;
0 commit comments