Skip to content

Commit 43aa56d

Browse files
committed
chore: update eslint to ^9.0.0
1 parent 3dbafad commit 43aa56d

File tree

4 files changed

+211
-276
lines changed

4 files changed

+211
-276
lines changed

.yarn/install-state.gz

-11.3 KB
Binary file not shown.

index.js

Lines changed: 83 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -1,86 +1,89 @@
1-
"use strict";
2-
3-
module.exports = {
4-
parserOptions: {
5-
ecmaVersion: 2019,
6-
sourceType: "module",
7-
ecmaFeatures: {
8-
jsx: true,
1+
export default [
2+
{
3+
parserOptions: {
4+
ecmaVersion: 2019,
5+
sourceType: "module",
6+
ecmaFeatures: {
7+
jsx: true,
8+
},
99
},
10-
},
11-
settings: {
12-
react: {
13-
version: "detect",
10+
settings: {
11+
react: {
12+
version: "detect",
13+
},
1414
},
15-
},
16-
plugins: ["jsdoc", "@typescript-eslint", "react-hooks"],
17-
extends: [
18-
"plugin:react-hooks/recommended",
19-
"plugin:react/recommended",
20-
"prettier",
21-
],
22-
parser: "@typescript-eslint/parser",
23-
rules: {
24-
curly: "error",
25-
"dot-notation": "off",
26-
"eol-last": "error",
27-
eqeqeq: ["error", "always", { null: "ignore" }],
28-
"guard-for-in": "off",
29-
"jsdoc/check-alignment": "error",
30-
"new-parens": "error",
31-
"no-array-constructor": "error",
32-
"no-bitwise": "off",
33-
"no-caller": "error",
34-
"no-cond-assign": "error",
35-
"no-console": ["error", { allow: ["error", "log", "warn", "info"] }],
36-
"no-debugger": "error",
37-
"no-empty": "off",
38-
"no-eval": "error",
39-
"no-fallthrough": "off",
40-
"no-new-wrappers": "error",
41-
"no-redeclare": "error",
42-
"no-restricted-imports": ["error", "moment"],
43-
"no-shadow": "off",
44-
"no-unused-expressions": "off",
45-
"no-unused-labels": "error",
46-
"no-var": "error",
47-
radix: "error",
48-
"sort-keys": "off",
49-
"spaced-comment": ["off", "always"],
50-
"use-isnan": "error",
51-
"no-duplicate-imports": "error",
52-
"@typescript-eslint/no-unused-expressions": [
53-
"error",
54-
{ allowShortCircuit: true, allowTernary: true },
15+
plugins: ["jsdoc", "@typescript-eslint", "react-hooks"],
16+
extends: [
17+
"plugin:react-hooks/recommended",
18+
"plugin:react/recommended",
19+
"prettier",
5520
],
56-
"@typescript-eslint/array-type": ["error", { default: "array-simple" }],
57-
"@typescript-eslint/naming-convention": [
58-
"error",
59-
{
60-
selector: "interface",
61-
format: ["PascalCase"],
62-
custom: {
63-
regex: "^I[A-Z]",
64-
match: false,
21+
parser: "@typescript-eslint/parser",
22+
rules: {
23+
curly: "error",
24+
"dot-notation": "off",
25+
"eol-last": "error",
26+
eqeqeq: ["error", "always", { null: "ignore" }],
27+
"guard-for-in": "off",
28+
"jsdoc/check-alignment": "error",
29+
"new-parens": "error",
30+
"no-array-constructor": "error",
31+
"no-bitwise": "off",
32+
"no-caller": "error",
33+
"no-cond-assign": "error",
34+
"no-console": ["error", { allow: ["error", "log", "warn", "info"] }],
35+
"no-debugger": "error",
36+
"no-empty": "off",
37+
"no-eval": "error",
38+
"no-fallthrough": "off",
39+
"no-new-wrappers": "error",
40+
"no-redeclare": "error",
41+
"no-restricted-imports": ["error", "moment"],
42+
"no-shadow": "off",
43+
"no-unused-expressions": "off",
44+
"no-unused-labels": "error",
45+
"no-var": "error",
46+
radix: "error",
47+
"sort-keys": "off",
48+
"spaced-comment": ["off", "always"],
49+
"use-isnan": "error",
50+
"no-duplicate-imports": "error",
51+
"@typescript-eslint/no-unused-expressions": [
52+
"error",
53+
{ allowShortCircuit: true, allowTernary: true },
54+
],
55+
"@typescript-eslint/array-type": ["error", { default: "array-simple" }],
56+
"@typescript-eslint/naming-convention": [
57+
"error",
58+
{
59+
selector: "interface",
60+
format: ["PascalCase"],
61+
custom: {
62+
regex: "^I[A-Z]",
63+
match: false,
64+
},
6565
},
66-
},
67-
],
68-
"@typescript-eslint/consistent-type-assertions": "error",
69-
"@typescript-eslint/no-inferrable-types": "error",
70-
"@typescript-eslint/no-namespace": ["error", { allowDeclarations: false }],
71-
"@typescript-eslint/no-unused-vars": "off",
72-
"@typescript-eslint/no-use-before-define": "off",
73-
"@typescript-eslint/triple-slash-reference": "error",
74-
"@typescript-eslint/type-annotation-spacing": [
75-
"error",
76-
{
77-
after: true,
78-
before: false,
79-
overrides: {
80-
arrow: { after: true, before: true },
66+
],
67+
"@typescript-eslint/consistent-type-assertions": "error",
68+
"@typescript-eslint/no-inferrable-types": "error",
69+
"@typescript-eslint/no-namespace": [
70+
"error",
71+
{ allowDeclarations: false },
72+
],
73+
"@typescript-eslint/no-unused-vars": "off",
74+
"@typescript-eslint/no-use-before-define": "off",
75+
"@typescript-eslint/triple-slash-reference": "error",
76+
"@typescript-eslint/type-annotation-spacing": [
77+
"error",
78+
{
79+
after: true,
80+
before: false,
81+
overrides: {
82+
arrow: { after: true, before: true },
83+
},
8184
},
82-
},
83-
],
84-
"react-hooks/exhaustive-deps": "error",
85+
],
86+
"react-hooks/exhaustive-deps": "error",
87+
},
8588
},
86-
};
89+
];

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"dependencies": {
2424
"@typescript-eslint/eslint-plugin": "6.18.1",
2525
"@typescript-eslint/parser": "6.18.1",
26-
"eslint": "8.52.0",
26+
"eslint": "^9.0.0",
2727
"eslint-config-prettier": "8.8.0",
2828
"eslint-plugin-jsdoc": "46.8.2",
2929
"eslint-plugin-react": "7.33.2",

0 commit comments

Comments
 (0)