forked from facebook/sapling
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.oxlintrc.json
More file actions
94 lines (88 loc) · 2.47 KB
/
Copy path.oxlintrc.json
File metadata and controls
94 lines (88 loc) · 2.47 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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
{
"$schema": "./node_modules/oxlint/configuration_schema.json",
"plugins": ["typescript", "react", "import"],
"jsPlugins": [{"name": "custom", "specifier": "./eslint-rules/index.js"}],
"categories": {
"correctness": "error"
},
"ignorePatterns": [
"components/vite.config.ts",
"isl/build.js",
"isl/release.js",
"isl/start.js",
"isl-server/codegen.js",
"isl-server/src/__generated__/**",
"isl-server/facebook/codegen.js",
"vscode/facebook/buildInternalExtension.*",
"node_modules/**",
"isl/src/third-party/**"
],
"rules": {
"@typescript-eslint/no-unused-vars": [
"warn",
{
"argsIgnorePattern": "^_",
"caughtErrorsIgnorePattern": "^_"
}
],
"@typescript-eslint/consistent-type-imports": "error",
"curly": "error",
"dot-notation": "error",
"no-await-in-loop": "error",
"no-bitwise": "error",
"no-caller": "error",
"no-console": "warn",
"no-constant-condition": "error",
"no-debugger": "error",
"no-duplicate-case": "error",
"no-empty": [
"error",
{
"allowEmptyCatch": true
}
],
"no-eval": "error",
"no-ex-assign": "error",
"no-fallthrough": "error",
"no-new-wrappers": "error",
"no-param-reassign": "error",
"no-script-url": "error",
"no-self-compare": "error",
"no-unsafe-finally": "error",
"no-unused-expressions": [
"error",
{
"allowShortCircuit": true,
"allowTernary": true
}
],
"no-var": "error",
"yoda": "error",
"no-restricted-imports": [
"error",
{
"paths": [
{
"name": "jotai/utils",
"importNames": ["atomFamily"],
"message": "atomFamily leaks memory. Use atomFamilyWeak(keyToAtom), or cached(keyToAtom), or useAtomValue(useMemo(() => keyToAtom(k), [k])), or useAtomGet and useAtomHas instead."
},
{
"name": "react-dom/test-utils",
"importNames": ["act"],
"message": "Prefer importing act from @testing-library/react instead."
}
]
}
],
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "error",
"import/no-duplicates": "error",
"custom/jotai-maybe-use-family": "error",
"custom/internal-promise-callback-types": "error",
"custom/no-facebook-imports": "error",
"require-await": "warn",
"no-async-promise-executor": "warn",
"sort-imports": "off"
}
}