Skip to content

Commit 0405707

Browse files
philibearenovate[bot]matthprost
authored
chore(oxlint): upgrade rule (#5778)
* chore(devdeps): update oxlint monorepo to v1.16.0 * fix: oxlint errors Signed-off-by: aphilibeaux <[email protected]> * chore(devdeps): update oxlint monorepo to v1.16.0 (#5566) * chore(devdeps): update oxlint monorepo to v1.16.0 * fix: oxlint errors Signed-off-by: aphilibeaux <[email protected]> --------- Signed-off-by: aphilibeaux <[email protected]> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Matthias <[email protected]> Signed-off-by: aphilibeaux <[email protected]> --------- Signed-off-by: aphilibeaux <[email protected]> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Matthias <[email protected]>
1 parent d8dd2f4 commit 0405707

File tree

101 files changed

+1524
-1333
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

101 files changed

+1524
-1333
lines changed

.oxlintrc.json

Lines changed: 100 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
{
22
"$schema": "./node_modules/oxlint/configuration_schema.json",
3+
"categories": {
4+
"correctness": "deny",
5+
"nursery": "off",
6+
"pedantic": "deny",
7+
"perf": "deny",
8+
"restriction": "deny",
9+
"style": "deny",
10+
"suspicious": "deny"
11+
},
312
"ignorePatterns": [
413
"**/app.config.d.ts",
514
"**/package.config.d.ts",
@@ -8,32 +17,23 @@
817
"*.d.ts",
918
"svgo.config.mjs"
1019
],
11-
"categories": {
12-
"correctness": "deny",
13-
"style": "deny",
14-
"suspicious": "deny",
15-
"perf": "deny",
16-
"pedantic": "deny",
17-
"restriction": "deny",
18-
"nursery": "off"
19-
},
20-
"plugins": [
21-
"import",
22-
"node",
23-
"oxc",
24-
"react",
25-
"typescript",
26-
"unicorn",
27-
"jsx-a11y"
28-
],
2920
"overrides": [
3021
{
31-
"files": ["**/__stories__/**/*.{ts,tsx}", "**/__tests__/**/*.{ts,tsx}", ".storybook/**/*.{ts,tsx}"],
22+
"files": [
23+
"**/__stories__/**/*.{ts,tsx}",
24+
"**/__tests__/**/*.{ts,tsx}",
25+
".storybook/**/*.{ts,tsx}",
26+
"exemples/**",
27+
".storybook/**/*.{ts,tsx}"
28+
],
3229
"rules": {
33-
"eslint/no-console": "off",
3430
"eslint/no-alert": "off",
31+
"eslint/no-console": "off",
3532
"import/no-anonymous-default-export": "off",
36-
"import/no-unassigned-import": "off"
33+
"import/no-named-export": "off",
34+
"import/no-unassigned-import": "off",
35+
"react/jsx-pascal-case": "off",
36+
"react/only-export-components": "off"
3737
}
3838
},
3939
{
@@ -45,46 +45,40 @@
4545
"setup.ts",
4646
"vitest.setup.ts",
4747
"**/vitest.setup.ts",
48-
"*.config.ts"
48+
"*.config.ts",
49+
"**/vitest/setup.ts"
4950
],
5051
"plugins": ["import", "oxc", "vitest"],
5152
"rules": {
5253
"@typescript-eslint/consistent-type-imports": "off",
53-
"import/no-namespace": "off",
5454
"import/export": "off",
5555
"import/no-anonymous-default-export": "off",
56+
"import/no-named-export": "off",
57+
"import/no-namespace": "off",
5658
"import/no-unassigned-import": "off",
5759
"jsx_a11y/label-has-associated-control": "off",
58-
"vitest/prefer-lowercase-title": "error",
59-
"no-console": "off"
60+
"no-console": "off",
61+
"node/no-process-env": "off",
62+
"vitest/prefer-lowercase-title": "error"
63+
}
64+
},
65+
{
66+
"files": ["e2e/**/*.{ts,tsx}"],
67+
"rules": {
68+
"node/no-process-env": "off"
6069
}
6170
}
6271
],
72+
"plugins": [
73+
"import",
74+
"node",
75+
"oxc",
76+
"react",
77+
"typescript",
78+
"unicorn",
79+
"jsx-a11y"
80+
],
6381
"rules": {
64-
"jsx_a11y/label-has-associated-control": "off",
65-
"jsx_a11y/no-autofocus": "off",
66-
"jsx_a11y/prefer-tag-over-role": "off",
67-
"import/default": "error",
68-
"import/export": "off",
69-
"import/exports-last": "off",
70-
"import/max-dependencies": "off",
71-
"import/named": "error",
72-
"import/no-amd": "error",
73-
"import/consistent-type-specifier-style": "error",
74-
"import/group-exports": "off",
75-
"import/import-no-namespace": "off",
76-
"import/namespace": "off",
77-
"import/no-cycle": "error",
78-
"import/no-default-export": "off",
79-
"import/no-duplicates": "error",
80-
"import/no-named-as-default-member": "error",
81-
"import/no-named-as-default": "error",
82-
"import/no-self-import": "error",
83-
"import/no-unassigned-import": "off",
84-
"import/no-unused-modules": "off",
85-
"import/prefer-default-export": "off",
86-
"import/no-namespace": "off",
87-
"import/unambiguous": "error",
8882
"@typescript-eslint/adjacent-overload-signatures": "error",
8983
"@typescript-eslint/array-type": "error",
9084
"@typescript-eslint/ban-ts-comment": "error",
@@ -97,42 +91,47 @@
9791
"@typescript-eslint/no-duplicate-enum-values": "error",
9892
"@typescript-eslint/no-empty-interface": "error",
9993
"@typescript-eslint/no-explicit-any": "error",
100-
"@typescript-eslint/no-magic-numbers": "off",
10194
"@typescript-eslint/no-extra-non-null-assertion": "error",
95+
"@typescript-eslint/no-magic-numbers": "off",
10296
"@typescript-eslint/no-misused-new": "error",
10397
"@typescript-eslint/no-namespace": "error",
10498
"@typescript-eslint/no-non-null-asserted-optional-chain": "error",
10599
"@typescript-eslint/no-non-null-assertion": "off",
106100
"@typescript-eslint/no-this-alias": "error",
107101
"@typescript-eslint/no-unnecessary-type-constraint": "error",
108102
"@typescript-eslint/no-unsafe-declaration-merging": "error",
103+
"@typescript-eslint/no-unsafe-member-access": "error",
109104
"@typescript-eslint/no-var-requires": "error",
110105
"@typescript-eslint/prefer-as-const": "error",
111-
"@typescript-eslint/no-unsafe-member-access": "error",
112106
"@typescript-eslint/prefer-enum-initializers": "off",
113107
"@typescript-eslint/prefer-for-of": "error",
114108
"@typescript-eslint/prefer-function-type": "off",
115109
"@typescript-eslint/prefer-literal-enum-member": "off",
116110
"@typescript-eslint/prefer-ts-expect-error": "off",
117111
"@typescript-eslint/triple-slash-reference": "error",
118-
"eslint/yoda": "error",
112+
"arrow-body-style": "off",
119113
"eslint/array-callback-return": "error",
120114
"eslint/constructor-super": "error",
121115
"eslint/default-case-last": "error",
122116
"eslint/default-param-last": "off",
123117
"eslint/eqeqeq": "error",
124118
"eslint/for-direction": "error",
119+
"eslint/func-style": "off",
125120
"eslint/getter-return": "error",
126121
"eslint/guard-for-in": "error",
122+
"eslint/id-length": "off",
123+
"eslint/init-declarations": "off",
127124
"eslint/max-classes-per-file": "error",
125+
"eslint/max-depth": "off",
128126
"eslint/max-lines": "off",
127+
"eslint/max-lines-per-function": "off",
128+
"eslint/max-nested-callbacks": "off",
129129
"eslint/max-params": "off",
130130
"eslint/no-array-constructor": "error",
131131
"eslint/no-async-promise-executor": "error",
132132
"eslint/no-await-in-loop": "off",
133133
"eslint/no-bitwise": "error",
134134
"eslint/no-caller": "error",
135-
"eslint/id-length": "off",
136135
"eslint/no-case-declarations": "error",
137136
"eslint/no-class-assign": "error",
138137
"eslint/no-compare-neg-zero": "error",
@@ -150,11 +149,11 @@
150149
"eslint/no-dupe-keys": "error",
151150
"eslint/no-duplicate-case": "error",
152151
"eslint/no-duplicate-imports": "off",
152+
"eslint/no-empty": "error",
153153
"eslint/no-empty-character-class": "error",
154154
"eslint/no-empty-function": "off",
155155
"eslint/no-empty-pattern": "error",
156156
"eslint/no-empty-static-block": "error",
157-
"eslint/no-empty": "error",
158157
"eslint/no-eq-null": "error",
159158
"eslint/no-eval": "error",
160159
"eslint/no-ex-assign": "error",
@@ -195,8 +194,6 @@
195194
"eslint/no-unsafe-optional-chaining": "error",
196195
"eslint/no-unused-labels": "error",
197196
"eslint/no-unused-private-class-members": "error",
198-
"eslint/sort-keys": "off",
199-
"eslint/react-in-jsx-scope": "off",
200197
"eslint/no-unused-vars": [
201198
"error",
202199
{
@@ -210,6 +207,7 @@
210207
"eslint/no-void": "error",
211208
"eslint/no-with": "error",
212209
"eslint/radix": "error",
210+
"eslint/react-in-jsx-scope": "off",
213211
"eslint/require-await": "off",
214212
"eslint/require-yield": "error",
215213
"eslint/sort-imports": [
@@ -219,45 +217,71 @@
219217
"memberSyntaxSortOrder": ["single", "multiple", "all", "none"]
220218
}
221219
],
220+
"eslint/sort-keys": "off",
222221
"eslint/unicode-bom": "error",
223222
"eslint/use-isnan": "error",
224223
"eslint/valid-typeof": "error",
225-
"eslint/init-declarations": "off",
226-
"eslint/func-style": "off",
227-
"eslint/max-lines-per-function": "off",
228-
"eslint/max-nested-callbacks": "off",
229-
"eslint/max-depth": "off",
224+
"eslint/yoda": "error",
225+
"import/consistent-type-specifier-style": "error",
226+
"import/default": "error",
227+
"import/export": "off",
228+
"import/exports-last": "off",
229+
"import/group-exports": "off",
230+
"import/import-no-namespace": "off",
231+
"import/max-dependencies": "off",
232+
"import/named": "error",
233+
"import/namespace": "off",
234+
"import/no-amd": "error",
235+
"import/no-anonymous-default-export": "off",
236+
"import/no-cycle": "error",
237+
"import/no-default-export": "off",
238+
"import/no-duplicates": "error",
239+
"import/no-named-as-default": "error",
240+
"import/no-named-as-default-member": "error",
241+
"import/no-named-export": "off",
242+
"import/no-namespace": "off",
243+
"import/no-self-import": "error",
244+
"import/no-unassigned-import": "off",
245+
"import/no-unused-modules": "off",
246+
"import/prefer-default-export": "off",
247+
"import/unambiguous": "error",
248+
"jsx_a11y/label-has-associated-control": "off",
249+
"jsx_a11y/no-autofocus": "off",
250+
"jsx_a11y/prefer-tag-over-role": "off",
230251
"oxc/bad-bitwise-operator": "error",
231252
"oxc/no-accumulating-spread": "off",
232253
"oxc/no-async-await": "off",
233254
"oxc/no-barrel-file": "off",
234255
"oxc/no-const-enum": "error",
235256
"oxc/no-optional-chaining": "off",
236257
"oxc/no-rest-spread-properties": "off",
237-
"react-perf/jsx-no-jsx-as-prop": "off",
238-
"react-perf/jsx-no-new-array-as-prop": "off",
239-
"react-perf/jsx-no-new-function-as-prop": "off",
240-
"react-perf/jsx-no-new-object-as-prop": "off",
258+
"prefer-destructuring": "off",
241259
"react_perf/jsx-no-jsx-as-prop": "error",
242260
"react_perf/jsx-no-new-array-as-prop": "error",
243261
"react_perf/jsx-no-new-function-as-props": "error",
244262
"react_perf/jsx-no-new-object-as-prop": "error",
263+
"react-perf/jsx-no-jsx-as-prop": "off",
264+
"react-perf/jsx-no-new-array-as-prop": "off",
265+
"react-perf/jsx-no-new-function-as-prop": "off",
266+
"react-perf/jsx-no-new-object-as-prop": "off",
245267
"react/button-has-type": "off",
246268
"react/exhaustive-deps": "error",
269+
"react/iframe-missing-sandbox": "error",
247270
"react/jsx-filename-extension": [
248271
"error",
249272
{
250273
"extensions": [".jsx", ".tsx"]
251274
}
252275
],
253-
"react/iframe-missing-sandbox": "error",
276+
"react/jsx-handler-names": "off",
254277
"react/jsx-key": "error",
255278
"react/jsx-no-comment-text-nodes": "error",
256279
"react/jsx-no-duplicate-props": "error",
257280
"react/jsx-no-target-blank": "off",
258281
"react/jsx-no-undef": "error",
259282
"react/jsx-no-useless-fragment": "off",
260283
"react/no-children-prop": "error",
284+
"react/no-danger": "off",
261285
"react/no-dangerously-set-inner-html": "error",
262286
"react/no-direct-mutation-state": "error",
263287
"react/no-find-dom-node": "error",
@@ -269,13 +293,7 @@
269293
"react/no-unknown-property": "error",
270294
"react/react-in-jsx-scope": "off",
271295
"react/require-render-return": "error",
272-
"react/no-danger": "off",
273-
"unicorn/no-instanceof-builtins": "error",
274-
"unicorn/prefer-array-index-of": "off",
275-
"unicorn/prefer-array-find": "off",
276-
"unicorn/no-for-loop": "off",
277-
"unicorn/prefer-object-from-entries": "off",
278-
"unicorn/prefer-global-this": "off",
296+
"typescript/explicit-module-boundary-types": "off",
279297
"unicorn/catch-error-name": "error",
280298
"unicorn/empty-brace-spaces": "error",
281299
"unicorn/error-message": "off",
@@ -289,12 +307,13 @@
289307
"unicorn/no-array-reduce": "off",
290308
"unicorn/no-await-expression-member": "off",
291309
"unicorn/no-await-in-promise-methods": "off",
292-
"unicorn/prefer-set-has": "off",
293310
"unicorn/no-console-spaces": "error",
294311
"unicorn/no-document-cookie": "off",
295312
"unicorn/no-empty-file": "error",
313+
"unicorn/no-for-loop": "off",
296314
"unicorn/no-hex-escape": "error",
297315
"unicorn/no-instanceof-array": "error",
316+
"unicorn/no-instanceof-builtins": "error",
298317
"unicorn/no-invalid-remove-event-listener": "off",
299318
"unicorn/no-lonely-if": "error",
300319
"unicorn/no-magic-array-flat-depth": "off",
@@ -323,9 +342,12 @@
323342
"unicorn/number-literal-case": "off",
324343
"unicorn/numeric-separators-style": "off",
325344
"unicorn/prefer-add-event-listener": "off",
345+
"unicorn/prefer-array-find": "off",
326346
"unicorn/prefer-array-flat": "error",
327347
"unicorn/prefer-array-flat-map": "error",
348+
"unicorn/prefer-array-index-of": "off",
328349
"unicorn/prefer-array-some": "off",
350+
"unicorn/prefer-at": "warn",
329351
"unicorn/prefer-blob-reading-methods": "off",
330352
"unicorn/prefer-code-point": "off",
331353
"unicorn/prefer-date-now": "error",
@@ -334,6 +356,7 @@
334356
"unicorn/prefer-dom-node-remove": "off",
335357
"unicorn/prefer-dom-node-text-content": "error",
336358
"unicorn/prefer-event-target": "error",
359+
"unicorn/prefer-global-this": "off",
337360
"unicorn/prefer-includes": "error",
338361
"unicorn/prefer-logical-operator-over-ternary": "off",
339362
"unicorn/prefer-math-trunc": "error",
@@ -342,11 +365,13 @@
342365
"unicorn/prefer-native-coercion-functions": "error",
343366
"unicorn/prefer-node-protocol": "off",
344367
"unicorn/prefer-number-properties": "error",
368+
"unicorn/prefer-object-from-entries": "off",
345369
"unicorn/prefer-optional-catch-binding": "error",
346370
"unicorn/prefer-prototype-methods": "error",
347371
"unicorn/prefer-query-selector": "off",
348372
"unicorn/prefer-reflect-apply": "error",
349373
"unicorn/prefer-regexp-test": "error",
374+
"unicorn/prefer-set-has": "off",
350375
"unicorn/prefer-set-size": "error",
351376
"unicorn/prefer-spread": "error",
352377
"unicorn/prefer-string-replace-all": "off",
@@ -358,12 +383,7 @@
358383
"unicorn/require-number-to-fixed-digits-argument": "error",
359384
"unicorn/switch-case-braces": "error",
360385
"unicorn/text-encoding-identifier-case": "error",
361-
"unicorn/throw-new-error": "error",
362-
"arrow-body-style": "off",
363-
"typescript/explicit-module-boundary-types": "off",
364-
"prefer-destructuring": "off",
365-
"import/no-anonymous-default-export": "off",
366-
"react/jsx-handler-names": "off"
386+
"unicorn/throw-new-error": "error"
367387
},
368388
"settings": {
369389
"jsx-a11y": {

biome.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
},
1212
"includes": [
1313
"!**/package.json",
14+
".oxlintrc.json",
1415
"**/*.ts",
1516
"**/*.tsx",
1617
"!**/dist/**",

e2e/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"@types/react": "19.2.2",
2828
"@types/react-dom": "19.2.2",
2929
"@vitejs/plugin-react": "5.0.4",
30-
"eslint": "9.38.0",
30+
"eslint": "9.39.1",
3131
"eslint-plugin-react-hooks": "6.1.1",
3232
"eslint-plugin-react-refresh": "0.4.24",
3333
"globals": "16.4.0",

eslint.config.mjs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ const dirname = path.dirname(filename)
1717
const disableRules = {
1818
// ---- biome rules ----
1919
'import/order': 'off',
20+
"sort-imports": "off",
2021
'import/no-unresolved': 'off',
2122
'@stylistic/no-extra-semi': 'off',
2223
'@stylistic/brace-style': 'off',

0 commit comments

Comments
 (0)