-
-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy patheslint.config.mjs
More file actions
56 lines (54 loc) · 1.23 KB
/
eslint.config.mjs
File metadata and controls
56 lines (54 loc) · 1.23 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
import xo from "eslint-config-xo";
import tseslint from "typescript-eslint";
import prettier from "eslint-config-prettier/flat";
import js from "@eslint/js";
export default tseslint.config(
{
ignores: [
"**/coverage",
"dist/",
"docs/tools/",
"theme/",
"**/webpack.config.js",
"**/build",
// TODO: lint fixtures and test, but make sure they don't end up in the
// bundle
"**/__fixtures__",
"**/__tests__",
"**/__mocks__",
],
},
{
extends: [
xo,
js.configs.recommended,
tseslint.configs.recommended,
tseslint.configs.recommendedTypeChecked,
prettier,
],
languageOptions: {
parserOptions: {
projectService: true,
tsconfigRootDir: import.meta.dirname,
},
},
rules: {
complexity: "off",
"@typescript-eslint/no-namespace": "off",
"no-warning-comments": "off",
"no-implicit-coercion": "off",
"no-void": ["error", { allowAsStatement: true }],
camelcase: [
"warn",
{
allow: [
"function_parameters",
"function_body",
"function_indentation",
],
},
],
},
files: ["**/*.ts"],
},
);