-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathoxlint.config.ts
More file actions
64 lines (63 loc) · 2.09 KB
/
Copy pathoxlint.config.ts
File metadata and controls
64 lines (63 loc) · 2.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
import { configs as userscriptsConfigs } from "eslint-plugin-userscripts";
import { defineConfig } from "oxlint";
export default defineConfig({
categories: {
correctness: "error",
},
options: {
typeAware: true,
},
settings: {
userscriptVersions: {
violentmonkey: "*",
},
},
ignorePatterns: ["dist"],
overrides: [
{
files: ["src/**/*.ts"],
rules: {
"no-implied-eval": "off",
"no-throw-literal": "off",
"prefer-promise-reject-errors": "off",
"require-await": "off",
"typescript/await-thenable": "error",
"typescript/no-array-delete": "error",
"typescript/no-base-to-string": "error",
"typescript/no-duplicate-type-constituents": "error",
"typescript/no-floating-promises": "error",
"typescript/no-for-in-array": "error",
"typescript/no-implied-eval": "error",
"typescript/no-misused-promises": "error",
"typescript/no-redundant-type-constituents": "error",
"typescript/no-unnecessary-type-assertion": "error",
"typescript/no-unsafe-argument": "error",
"typescript/no-unsafe-assignment": "error",
"typescript/no-unsafe-call": "error",
"typescript/no-unsafe-enum-comparison": "error",
"typescript/no-unsafe-member-access": "error",
"typescript/no-unsafe-return": "error",
"typescript/no-unsafe-unary-minus": "error",
"typescript/only-throw-error": "error",
"typescript/prefer-promise-reject-errors": "error",
"typescript/require-await": "error",
"typescript/restrict-plus-operands": "error",
"typescript/restrict-template-expressions": "error",
"typescript/unbound-method": "error",
},
},
{
files: ["**/*.user.ts", "**/*.user.js"],
jsPlugins: ["eslint-plugin-userscripts"],
rules: userscriptsConfigs.recommended.rules,
},
{
files: ["**/*.user.ts"],
jsPlugins: ["eslint-plugin-userscripts"],
rules: {
"userscripts/no-invalid-metadata": "off",
"userscripts/filename-user": "off",
},
},
],
});