eslint-config-seekingalpha-base 9.1.0 → 11.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # Change Log
2
2
 
3
+ ## 11.0.0 - 2025-03-09
4
+
5
+ - [deps] update `eslint` to version `9.22.0`
6
+ - [breaking] enable `unicorn/prefer-math-min-max` rule
7
+ - [breaking] enable `no-useless-assignment` rule
8
+
9
+ ## 10.0.0 - 2025-03-09
10
+
11
+ - [breaking] migrate to ESM and make flat config default
12
+
3
13
  ## 9.1.0 - 2025-03-06
4
14
 
5
15
  - [deps] update `eslint-plugin-array-func` to version `5.0.2`
package/README.md CHANGED
@@ -6,36 +6,39 @@ This package includes the shareable ESLint config used by [SeekingAlpha](https:/
6
6
 
7
7
  Install ESLint and all [Peer Dependencies](https://nodejs.org/en/blog/npm/peer-dependencies/):
8
8
 
9
- npm install eslint@8.57.1 eslint-plugin-array-func@5.0.2 eslint-plugin-import@2.31.0 eslint-plugin-promise@7.2.1 eslint-plugin-unicorn@56.0.1 --save-dev
9
+ npm install eslint@9.22.0 eslint-plugin-array-func@5.0.2 eslint-plugin-import@2.31.0 eslint-plugin-promise@7.2.1 eslint-plugin-unicorn@56.0.1 --save-dev
10
10
 
11
11
  Install SeekingAlpha shareable ESLint:
12
12
 
13
- npm install eslint-config-seekingalpha-base --save-dev
13
+ npm install eslint-config-seekingalpha-base@latest --save-dev
14
14
 
15
15
  ## Usage
16
16
 
17
- This shareable config includes all ESLint rules including ECMAScript 6 features and set of [legacy rules](https://eslint.org/docs/rules/#deprecated). We also extend our configuration with following plugins:
17
+ This shareable config includes all ESLint rules. We also extend our configuration with following plugins:
18
18
 
19
19
  - [eslint-plugin-import](https://github.com/benmosher/eslint-plugin-import)
20
20
  - [eslint-plugin-array-func](https://github.com/freaktechnik/eslint-plugin-array-func)
21
21
  - [eslint-plugin-promise](https://github.com/xjamundx/eslint-plugin-promise)
22
22
  - [eslint-plugin-unicorn](https://github.com/sindresorhus/eslint-plugin-unicorn)
23
23
 
24
- We expose three configurations:
25
-
26
- - `seekingalpha-base` - exports all avaliable ESLint [rules](https://eslint.org/docs/rules/) and all rules of plugins above.
27
- - `seekingalpha-base/browser` - exports only browser related rules for ESLint and mentioned plugins. It also sets `browser` as [default environment](https://eslint.org/docs/user-guide/configuring#specifying-environments).
28
- - `seekingalpha-base/node` - exports only Node.js related rules for ESLint and mentioned plugins. It also sets `node` as [default environment](https://eslint.org/docs/user-guide/configuring#specifying-environments).
29
-
30
- Simply [extend](https://eslint.org/docs/user-guide/configuring#extending-configuration-files) the .eslintrc.js in your project with relevant configuration:
24
+ Simply [use](https://eslint.org/docs/latest/extend/shareable-configs) the eslint.config.js in your project with the configuration:
31
25
 
32
26
  ```javascript
33
- // for seekingalpha-base
34
- {
35
- extends: [
36
- 'seekingalpha-base'
37
- ]
38
- }
27
+ import baseConfig from 'eslint-config-seekingalpha-base';
28
+
29
+ export default [
30
+ {
31
+ plugins: {
32
+ ...baseConfig.plugins,
33
+ },
34
+ rules: {
35
+ ...baseConfig.rules,
36
+ },
37
+ settings: {
38
+ ...baseConfig.settings,
39
+ },
40
+ },
41
+ ];
39
42
  ```
40
43
 
41
44
  ## License
package/index.js CHANGED
@@ -1,27 +1,24 @@
1
- module.exports = {
2
- extends: [
3
- // ESLint rules (https://eslint.org/docs/rules/)
4
- './rules/eslint/index.js',
1
+ import esLintConfig from './rules/eslint/index.js';
2
+ import esLintPluginArrayFuncConfig from './rules/eslint-plugin-array-func/index.js';
3
+ import esLintPluginImport from './rules/eslint-plugin-import/index.js';
4
+ import esLintPluginPromise from './rules/eslint-plugin-promise/index.js';
5
+ import esLintPluginUnicorn from './rules/eslint-plugin-unicorn/index.js';
5
6
 
6
- // eslint-plugin-import rules (https://github.com/benmosher/eslint-plugin-import)
7
- './rules/eslint-plugin-import/index.js',
8
-
9
- // eslint-plugin-array-func rules (https://github.com/freaktechnik/eslint-plugin-array-func)
10
- './rules/eslint-plugin-array-func/index.js',
11
-
12
- // eslint-plugin-promise rules (https://github.com/xjamundx/eslint-plugin-promise)
13
- './rules/eslint-plugin-promise/index.js',
14
-
15
- // eslint-plugin-unicorn rules (https://github.com/sindresorhus/eslint-plugin-unicorn)
16
- './rules/eslint-plugin-unicorn/index.js',
17
- ],
18
-
19
- parserOptions: {
20
- ecmaVersion: 12,
21
- sourceType: 'module',
22
- ecmaFeatures: {
23
- impliedStrict: true,
24
- globalReturn: false,
25
- },
7
+ export default {
8
+ plugins: {
9
+ ...esLintPluginArrayFuncConfig.plugins,
10
+ ...esLintPluginImport.plugins,
11
+ ...esLintPluginPromise.plugins,
12
+ ...esLintPluginUnicorn.plugins,
13
+ },
14
+ rules: {
15
+ ...esLintConfig.rules,
16
+ ...esLintPluginArrayFuncConfig.rules,
17
+ ...esLintPluginImport.rules,
18
+ ...esLintPluginPromise.rules,
19
+ ...esLintPluginUnicorn.rules,
20
+ },
21
+ settings: {
22
+ ...esLintPluginImport.settings,
26
23
  },
27
24
  };
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "eslint-config-seekingalpha-base",
3
- "version": "9.1.0",
3
+ "version": "11.0.0",
4
4
  "description": "SeekingAlpha's sharable base ESLint config",
5
5
  "main": "index.js",
6
+ "type": "module",
6
7
  "scripts": {
7
- "eslint-find-rules": "eslint-find-rules -u ./index.js",
8
- "lint": "eslint --ext .js .",
8
+ "eslint-find-rules": "eslint-find-rules --flatConfig -u ./index.js",
9
9
  "test": "echo \"Error: no test specified\" && exit 1"
10
10
  },
11
11
  "repository": {
@@ -48,14 +48,14 @@
48
48
  "node": ">= 22"
49
49
  },
50
50
  "peerDependencies": {
51
- "eslint": "8.57.1",
51
+ "eslint": "9.22.0",
52
52
  "eslint-plugin-array-func": "5.0.2",
53
53
  "eslint-plugin-import": "2.31.0",
54
54
  "eslint-plugin-promise": "7.2.1",
55
55
  "eslint-plugin-unicorn": "56.0.1"
56
56
  },
57
57
  "devDependencies": {
58
- "eslint": "8.57.1",
58
+ "eslint": "9.22.0",
59
59
  "eslint-find-rules": "5.0.0",
60
60
  "eslint-plugin-array-func": "5.0.2",
61
61
  "eslint-plugin-import": "2.31.0",
package/rules/config.js CHANGED
@@ -1,4 +1,4 @@
1
- module.exports = {
1
+ export default {
2
2
  complexity: 10,
3
3
  maxClassesPerFile: 1,
4
4
  arrayElementNewlineMinItems: 5,
@@ -1,7 +1,11 @@
1
- module.exports = {
2
- extends: [
3
- './possible-problems.js',
4
- './suggestions.js',
5
- './layout-and-formatting.js',
6
- ],
1
+ import layout from './layout-and-formatting.js';
2
+ import problems from './possible-problems.js';
3
+ import suggestions from './suggestions.js';
4
+
5
+ export default {
6
+ rules: {
7
+ ...layout,
8
+ ...problems,
9
+ ...suggestions,
10
+ },
7
11
  };
@@ -1,21 +1,8 @@
1
- module.exports = {
2
- // https://eslint.org/docs/rules/#layout-formatting
3
-
4
- rules: {
5
- // https://eslint.org/docs/rules/line-comment-position
6
- 'line-comment-position': [
7
- 'error',
8
- {
9
- position: 'above',
10
- ignorePattern: '',
11
- applyDefaultPatterns: true,
12
- },
13
- ],
14
-
15
- /*
16
- * https://eslint.org/docs/rules/unicode-bom
17
- * disabled to work with prettier
18
- */
19
- 'unicode-bom': 'off',
20
- },
1
+ // https://eslint.org/docs/rules/#layout-formatting
2
+ export default {
3
+ /*
4
+ * https://eslint.org/docs/rules/unicode-bom
5
+ * disabled to work with prettier
6
+ */
7
+ 'unicode-bom': 'off',
21
8
  };
@@ -1,223 +1,223 @@
1
- module.exports = {
2
- // https://eslint.org/docs/rules/#possible-problems
1
+ // https://eslint.org/docs/rules/#possible-problems
2
+ export default {
3
+ // https://eslint.org/docs/rules/array-callback-return
4
+ 'array-callback-return': 'error',
3
5
 
4
- rules: {
5
- // https://eslint.org/docs/rules/array-callback-return
6
- 'array-callback-return': 'error',
6
+ // https://eslint.org/docs/rules/constructor-super
7
+ 'constructor-super': 'error',
7
8
 
8
- // https://eslint.org/docs/rules/constructor-super
9
- 'constructor-super': 'error',
9
+ // https://eslint.org/docs/rules/for-direction
10
+ 'for-direction': 'error',
10
11
 
11
- // https://eslint.org/docs/rules/for-direction
12
- 'for-direction': 'error',
12
+ // https://eslint.org/docs/rules/getter-return
13
+ 'getter-return': [
14
+ 'error',
15
+ {
16
+ allowImplicit: false,
17
+ },
18
+ ],
13
19
 
14
- // https://eslint.org/docs/rules/getter-return
15
- 'getter-return': [
16
- 'error',
17
- {
18
- allowImplicit: false,
19
- },
20
- ],
20
+ // https://eslint.org/docs/rules/no-async-promise-executor
21
+ 'no-async-promise-executor': 'error',
21
22
 
22
- // https://eslint.org/docs/rules/no-async-promise-executor
23
- 'no-async-promise-executor': 'error',
23
+ // https://eslint.org/docs/rules/no-await-in-loop
24
+ 'no-await-in-loop': 'error',
24
25
 
25
- // https://eslint.org/docs/rules/no-await-in-loop
26
- 'no-await-in-loop': 'error',
26
+ // https://eslint.org/docs/rules/no-class-assign
27
+ 'no-class-assign': 'error',
27
28
 
28
- // https://eslint.org/docs/rules/no-class-assign
29
- 'no-class-assign': 'error',
29
+ // https://eslint.org/docs/rules/no-compare-neg-zero
30
+ 'no-compare-neg-zero': 'error',
30
31
 
31
- // https://eslint.org/docs/rules/no-compare-neg-zero
32
- 'no-compare-neg-zero': 'error',
32
+ // https://eslint.org/docs/rules/no-cond-assign
33
+ 'no-cond-assign': 'error',
33
34
 
34
- // https://eslint.org/docs/rules/no-cond-assign
35
- 'no-cond-assign': 'error',
35
+ // https://eslint.org/docs/rules/no-const-assign
36
+ 'no-const-assign': 'error',
36
37
 
37
- // https://eslint.org/docs/rules/no-const-assign
38
- 'no-const-assign': 'error',
38
+ // https://eslint.org/docs/rules/no-constant-binary-expression
39
+ 'no-constant-binary-expression': 'error',
39
40
 
40
- // https://eslint.org/docs/rules/no-constant-binary-expression
41
- 'no-constant-binary-expression': 'error',
41
+ // https://eslint.org/docs/rules/no-constant-condition
42
+ 'no-constant-condition': 'error',
42
43
 
43
- // https://eslint.org/docs/rules/no-constant-condition
44
- 'no-constant-condition': 'error',
44
+ // https://eslint.org/docs/rules/no-constructor-return
45
+ 'no-constructor-return': 'error',
45
46
 
46
- // https://eslint.org/docs/rules/no-constructor-return
47
- 'no-constructor-return': 'error',
47
+ // https://eslint.org/docs/rules/no-control-regex
48
+ 'no-control-regex': 'error',
48
49
 
49
- // https://eslint.org/docs/rules/no-control-regex
50
- 'no-control-regex': 'error',
50
+ // https://eslint.org/docs/rules/no-debugger
51
+ 'no-debugger': 'error',
51
52
 
52
- // https://eslint.org/docs/rules/no-debugger
53
- 'no-debugger': 'error',
53
+ // https://eslint.org/docs/rules/no-dupe-args
54
+ 'no-dupe-args': 'error',
54
55
 
55
- // https://eslint.org/docs/rules/no-dupe-args
56
- 'no-dupe-args': 'error',
56
+ // https://eslint.org/docs/rules/no-dupe-class-members
57
+ 'no-dupe-class-members': 'error',
57
58
 
58
- // https://eslint.org/docs/rules/no-dupe-class-members
59
- 'no-dupe-class-members': 'error',
59
+ // https://eslint.org/docs/rules/no-dupe-else-if
60
+ 'no-dupe-else-if': 'error',
60
61
 
61
- // https://eslint.org/docs/rules/no-dupe-else-if
62
- 'no-dupe-else-if': 'error',
62
+ // https://eslint.org/docs/rules/no-dupe-keys
63
+ 'no-dupe-keys': 'error',
63
64
 
64
- // https://eslint.org/docs/rules/no-dupe-keys
65
- 'no-dupe-keys': 'error',
65
+ // https://eslint.org/docs/rules/no-duplicate-case
66
+ 'no-duplicate-case': 'error',
66
67
 
67
- // https://eslint.org/docs/rules/no-duplicate-case
68
- 'no-duplicate-case': 'error',
68
+ // https://eslint.org/docs/rules/no-duplicate-imports
69
+ 'no-duplicate-imports': 'off',
69
70
 
70
- // https://eslint.org/docs/rules/no-duplicate-imports
71
- 'no-duplicate-imports': 'off',
71
+ // https://eslint.org/docs/rules/no-empty-character-class
72
+ 'no-empty-character-class': 'error',
72
73
 
73
- // https://eslint.org/docs/rules/no-empty-character-class
74
- 'no-empty-character-class': 'error',
74
+ // https://eslint.org/docs/rules/no-empty-pattern
75
+ 'no-empty-pattern': 'error',
75
76
 
76
- // https://eslint.org/docs/rules/no-empty-pattern
77
- 'no-empty-pattern': 'error',
77
+ /*
78
+ * https://eslint.org/docs/rules/no-ex-assign
79
+ * https://bocoup.com/blog/the-catch-with-try-catch
80
+ */
81
+ 'no-ex-assign': 'error',
78
82
 
79
- /*
80
- * https://eslint.org/docs/rules/no-ex-assign
81
- * https://bocoup.com/blog/the-catch-with-try-catch
82
- */
83
- 'no-ex-assign': 'error',
83
+ // https://eslint.org/docs/rules/no-fallthrough
84
+ 'no-fallthrough': 'error',
84
85
 
85
- // https://eslint.org/docs/rules/no-fallthrough
86
- 'no-fallthrough': 'error',
86
+ // https://eslint.org/docs/rules/no-func-assign
87
+ 'no-func-assign': 'error',
87
88
 
88
- // https://eslint.org/docs/rules/no-func-assign
89
- 'no-func-assign': 'error',
89
+ // https://eslint.org/docs/rules/no-import-assign
90
+ 'no-import-assign': 'error',
90
91
 
91
- // https://eslint.org/docs/rules/no-import-assign
92
- 'no-import-assign': 'error',
92
+ // https://eslint.org/docs/rules/no-inner-declarations
93
+ 'no-inner-declarations': 'error',
93
94
 
94
- // https://eslint.org/docs/rules/no-inner-declarations
95
- 'no-inner-declarations': 'error',
95
+ // https://eslint.org/docs/rules/no-invalid-regexp
96
+ 'no-invalid-regexp': 'error',
96
97
 
97
- // https://eslint.org/docs/rules/no-invalid-regexp
98
- 'no-invalid-regexp': 'error',
98
+ // https://eslint.org/docs/rules/no-irregular-whitespace
99
+ 'no-irregular-whitespace': 'error',
99
100
 
100
- // https://eslint.org/docs/rules/no-irregular-whitespace
101
- 'no-irregular-whitespace': 'error',
101
+ // https://eslint.org/docs/rules/no-loss-of-precision
102
+ 'no-loss-of-precision': 'error',
102
103
 
103
- // https://eslint.org/docs/rules/no-loss-of-precision
104
- 'no-loss-of-precision': 'error',
104
+ // https://eslint.org/docs/rules/no-misleading-character-class
105
+ 'no-misleading-character-class': 'error',
105
106
 
106
- // https://eslint.org/docs/rules/no-misleading-character-class
107
- 'no-misleading-character-class': 'error',
107
+ // https://eslint.org/docs/latest/rules/no-new-native-nonconstructor
108
+ 'no-new-native-nonconstructor': 'error',
108
109
 
109
- // https://eslint.org/docs/latest/rules/no-new-native-nonconstructor
110
- 'no-new-native-nonconstructor': 'error',
110
+ // https://eslint.org/docs/rules/no-new-symbol
111
+ 'no-new-symbol': 'error',
111
112
 
112
- // https://eslint.org/docs/rules/no-new-symbol
113
- 'no-new-symbol': 'error',
113
+ // https://eslint.org/docs/rules/no-obj-calls
114
+ 'no-obj-calls': 'error',
114
115
 
115
- // https://eslint.org/docs/rules/no-obj-calls
116
- 'no-obj-calls': 'error',
116
+ // https://eslint.org/docs/rules/no-promise-executor-return
117
+ 'no-promise-executor-return': 'error',
117
118
 
118
- // https://eslint.org/docs/rules/no-promise-executor-return
119
- 'no-promise-executor-return': 'error',
119
+ // https://eslint.org/docs/rules/no-prototype-builtins
120
+ 'no-prototype-builtins': 'error',
120
121
 
121
- // https://eslint.org/docs/rules/no-prototype-builtins
122
- 'no-prototype-builtins': 'error',
122
+ // https://eslint.org/docs/rules/no-self-assign
123
+ 'no-self-assign': [
124
+ 'error',
125
+ {
126
+ props: false,
127
+ },
128
+ ],
123
129
 
124
- // https://eslint.org/docs/rules/no-self-assign
125
- 'no-self-assign': [
126
- 'error',
127
- {
128
- props: false,
129
- },
130
- ],
130
+ // https://eslint.org/docs/rules/no-self-compare
131
+ 'no-self-compare': 'error',
131
132
 
132
- // https://eslint.org/docs/rules/no-self-compare
133
- 'no-self-compare': 'error',
133
+ // https://eslint.org/docs/rules/no-setter-return
134
+ 'no-setter-return': 'error',
134
135
 
135
- // https://eslint.org/docs/rules/no-setter-return
136
- 'no-setter-return': 'error',
136
+ /*
137
+ * https://eslint.org/docs/rules/no-sparse-arrays
138
+ * https://humanwhocodes.com/blog/2007/09/09/inconsistent-array-literals/
139
+ */
140
+ 'no-sparse-arrays': 'error',
137
141
 
138
- /*
139
- * https://eslint.org/docs/rules/no-sparse-arrays
140
- * https://humanwhocodes.com/blog/2007/09/09/inconsistent-array-literals/
141
- */
142
- 'no-sparse-arrays': 'error',
142
+ // https://eslint.org/docs/rules/no-template-curly-in-string
143
+ 'no-template-curly-in-string': 'error',
143
144
 
144
- // https://eslint.org/docs/rules/no-template-curly-in-string
145
- 'no-template-curly-in-string': 'error',
145
+ // https://eslint.org/docs/rules/no-this-before-super
146
+ 'no-this-before-super': 'error',
146
147
 
147
- // https://eslint.org/docs/rules/no-this-before-super
148
- 'no-this-before-super': 'error',
148
+ // https://eslint.org/docs/rules/no-undef
149
+ 'no-undef': 'error',
149
150
 
150
- // https://eslint.org/docs/rules/no-undef
151
- 'no-undef': 'error',
151
+ // https://eslint.org/docs/rules/no-unexpected-multiline
152
+ 'no-unexpected-multiline': 'error',
152
153
 
153
- // https://eslint.org/docs/rules/no-unexpected-multiline
154
- 'no-unexpected-multiline': 'error',
154
+ // https://eslint.org/docs/rules/no-unmodified-loop-condition
155
+ 'no-unmodified-loop-condition': 'error',
155
156
 
156
- // https://eslint.org/docs/rules/no-unmodified-loop-condition
157
- 'no-unmodified-loop-condition': 'error',
157
+ // https://eslint.org/docs/rules/no-unreachable
158
+ 'no-unreachable': 'error',
158
159
 
159
- // https://eslint.org/docs/rules/no-unreachable
160
- 'no-unreachable': 'error',
160
+ // https://eslint.org/docs/rules/no-unreachable-loop
161
+ 'no-unreachable-loop': 'error',
161
162
 
162
- // https://eslint.org/docs/rules/no-unreachable-loop
163
- 'no-unreachable-loop': 'error',
163
+ // https://eslint.org/docs/rules/no-unsafe-finally
164
+ 'no-unsafe-finally': 'error',
164
165
 
165
- // https://eslint.org/docs/rules/no-unsafe-finally
166
- 'no-unsafe-finally': 'error',
167
-
168
- // https://eslint.org/docs/rules/no-unsafe-negation
169
- 'no-unsafe-negation': 'error',
170
-
171
- // https://eslint.org/docs/rules/no-unsafe-optional-chaining
172
- 'no-unsafe-optional-chaining': [
173
- 'error',
174
- {
175
- disallowArithmeticOperators: true,
176
- },
177
- ],
178
-
179
- // https://eslint.org/docs/rules/no-unused-private-class-members
180
- 'no-unused-private-class-members': 'error',
181
-
182
- // https://eslint.org/docs/rules/no-unused-vars
183
- 'no-unused-vars': [
184
- 'error',
185
- {
186
- args: 'after-used',
187
- argsIgnorePattern: '[iI]gnored',
188
- caughtErrors: 'all',
189
- caughtErrorsIgnorePattern: '[iI]gnored',
190
- ignoreRestSiblings: false,
191
- vars: 'all',
192
- varsIgnorePattern: '[iI]gnored',
193
- },
194
- ],
195
-
196
- // https://eslint.org/docs/rules/no-use-before-define
197
- 'no-use-before-define': [
198
- 'error',
199
- {
200
- functions: true,
201
- classes: true,
202
- variables: true,
203
- },
204
- ],
205
-
206
- // https://eslint.org/docs/rules/no-useless-backreference
207
- 'no-useless-backreference': 'error',
208
-
209
- // https://eslint.org/docs/rules/require-atomic-updates
210
- 'require-atomic-updates': 'error',
211
-
212
- // https://eslint.org/docs/rules/use-isnan
213
- 'use-isnan': 'error',
214
-
215
- // https://eslint.org/docs/rules/valid-typeof
216
- 'valid-typeof': [
217
- 'error',
218
- {
219
- requireStringLiterals: true,
220
- },
221
- ],
222
- },
166
+ // https://eslint.org/docs/rules/no-unsafe-negation
167
+ 'no-unsafe-negation': 'error',
168
+
169
+ // https://eslint.org/docs/rules/no-unsafe-optional-chaining
170
+ 'no-unsafe-optional-chaining': [
171
+ 'error',
172
+ {
173
+ disallowArithmeticOperators: true,
174
+ },
175
+ ],
176
+
177
+ // https://eslint.org/docs/rules/no-unused-private-class-members
178
+ 'no-unused-private-class-members': 'error',
179
+
180
+ // https://eslint.org/docs/rules/no-unused-vars
181
+ 'no-unused-vars': [
182
+ 'error',
183
+ {
184
+ args: 'after-used',
185
+ argsIgnorePattern: '[iI]gnored',
186
+ caughtErrors: 'all',
187
+ caughtErrorsIgnorePattern: '[iI]gnored',
188
+ ignoreRestSiblings: false,
189
+ vars: 'all',
190
+ varsIgnorePattern: '[iI]gnored',
191
+ },
192
+ ],
193
+
194
+ // https://eslint.org/docs/rules/no-use-before-define
195
+ 'no-use-before-define': [
196
+ 'error',
197
+ {
198
+ functions: true,
199
+ classes: true,
200
+ variables: true,
201
+ },
202
+ ],
203
+
204
+ // https://eslint.org/docs/latest/rules/no-useless-assignment
205
+ 'no-useless-assignment': 'error',
206
+
207
+ // https://eslint.org/docs/rules/no-useless-backreference
208
+ 'no-useless-backreference': 'error',
209
+
210
+ // https://eslint.org/docs/rules/require-atomic-updates
211
+ 'require-atomic-updates': 'error',
212
+
213
+ // https://eslint.org/docs/rules/use-isnan
214
+ 'use-isnan': 'error',
215
+
216
+ // https://eslint.org/docs/rules/valid-typeof
217
+ 'valid-typeof': [
218
+ 'error',
219
+ {
220
+ requireStringLiterals: true,
221
+ },
222
+ ],
223
223
  };