|
1 | 1 | { |
2 | 2 | "$schema": "./node_modules/oxlint/configuration_schema.json", |
3 | | - "plugins": ["typescript", "import", "jsdoc", "jest", "vitest"], |
| 3 | + "plugins": ["typescript", "import", "jsdoc", "vitest"], |
4 | 4 | "jsPlugins": [ |
5 | 5 | { |
6 | 6 | "name": "sdk", |
|
9 | 9 | ], |
10 | 10 | "categories": {}, |
11 | 11 | "rules": { |
| 12 | + "no-unused-vars": [ |
| 13 | + "warn", |
| 14 | + { "argsIgnorePattern": "^_", "varsIgnorePattern": "^_", "caughtErrorsIgnorePattern": "^_" } |
| 15 | + ], |
| 16 | + |
12 | 17 | // === Base rules from eslint-config-sdk/base.js === |
13 | 18 | "no-console": "error", |
14 | 19 | "no-alert": "error", |
|
27 | 32 | "import/namespace": "off", |
28 | 33 | "import/no-unresolved": "off", |
29 | 34 |
|
30 | | - // === Jest/Vitest rules === |
31 | | - "jest/no-focused-tests": "error", |
32 | | - "jest/no-disabled-tests": "error", |
33 | | - |
34 | 35 | // === Rules turned off (not enforced in ESLint or causing false positives) === |
35 | 36 | "no-control-regex": "off", |
36 | 37 | "jsdoc/check-tag-names": "off", |
37 | 38 | "jsdoc/require-yields": "off", |
38 | 39 | "no-useless-rename": "off", |
39 | 40 | "no-constant-binary-expression": "off", |
40 | | - "jest/no-conditional-expect": "off", |
41 | | - "jest/expect-expect": "off", |
42 | | - "jest/no-standalone-expect": "off", |
43 | | - "jest/require-to-throw-message": "off", |
44 | | - "jest/valid-title": "off", |
45 | | - "jest/no-export": "off", |
46 | | - "jest/valid-describe-callback": "off", |
47 | 41 | "vitest/hoisted-apis-on-top": "off", |
48 | 42 | "vitest/no-conditional-tests": "off", |
49 | 43 | "no-unsafe-optional-chaining": "off", |
50 | 44 | "no-eval": "off", |
51 | 45 | "no-import-assign": "off", |
| 46 | + "typescript/no-duplicate-type-constituents": "off", |
52 | 47 |
|
53 | 48 | // === Custom SDK rules (via JS plugin) === |
54 | 49 | "sdk/no-eq-empty": "error" |
|
61 | 56 | "typescript/consistent-type-imports": "error", |
62 | 57 | "typescript/no-unnecessary-type-assertion": "error", |
63 | 58 | "typescript/prefer-for-of": "error", |
64 | | - // "typescript/no-floating-promises": ["error", { "ignoreVoid": false }], |
| 59 | + "typescript/no-floating-promises": ["error", { "ignoreVoid": true }], |
65 | 60 | "typescript/no-dynamic-delete": "error", |
66 | | - // "typescript/no-unsafe-member-access": "error", |
| 61 | + "typescript/no-unsafe-member-access": "error", |
67 | 62 | "typescript/unbound-method": "error", |
68 | 63 | "typescript/no-explicit-any": "error", |
69 | 64 | "typescript/no-empty-function": "off", |
70 | | - |
71 | | - // === FIXME: Rules to turn back as error === |
72 | | - "typescript/prefer-optional-chain": "warn", |
73 | | - "typescript/no-floating-promises": "warn", |
74 | | - "typescript/no-unsafe-member-access": "warn" |
| 65 | + "typescript/prefer-optional-chain": ["error"], |
| 66 | + "typescript/no-redundant-type-constituents": "off", |
| 67 | + "typescript/restrict-template-expressions": "off", |
| 68 | + "typescript/await-thenable": "warn", |
| 69 | + "typescript/no-base-to-string": "warn" |
75 | 70 | } |
76 | 71 | }, |
77 | 72 | { |
|
111 | 106 | "typescript/no-floating-promises": "off", |
112 | 107 | "typescript/unbound-method": "off", |
113 | 108 | "max-lines": "off", |
114 | | - "complexity": "off" |
| 109 | + "complexity": "off", |
| 110 | + "typescript/prefer-optional-chain": "off", |
| 111 | + "typescript/no-misused-spread": "off", |
| 112 | + "typescript/require-array-sort-compare": "off", |
| 113 | + "typescript/no-base-to-string": "off", |
| 114 | + "typescript/await-thenable": "off" |
115 | 115 | } |
116 | 116 | }, |
117 | 117 | { |
|
0 commit comments