-
-
Notifications
You must be signed in to change notification settings - Fork 30
/
eslint.config.js
50 lines (48 loc) · 1.09 KB
/
eslint.config.js
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
import sharedRules from "@schoero/configs/eslint";
import eslintPluginTypeScript from "@typescript-eslint/eslint-plugin";
import eslintParserTypeScript from "@typescript-eslint/parser";
/** @type { import("eslint").Linter.Config[] } */
export default [
...sharedRules,
{
ignores: [
"src/shared/qr-code-generator.ts",
"pdf",
"svg",
"utils",
"types",
"errors"
]
},
{
files: ["**/*.ts"],
rules: {
"eslint-plugin-typescript/no-unnecessary-condition": "off"
}
},
{
files: ["examples/**/*.js", "examples/**/*.ts"],
rules: {
"no-undef": "off"
}
},
{
files: ["vite.config.ts", "vite.config.cjs.ts", "vite.config.bundle.ts"],
languageOptions: {
parser: eslintParserTypeScript,
parserOptions: {
project: "./tsconfig.vite.json",
projectService: false
}
},
plugins: {
"eslint-plugin-typescript": eslintPluginTypeScript
}
},
{
files: ["examples/**/*.js", "examples/**/*.ts"],
rules: {
"eslint-plugin-unicorn/prefer-node-protocol": "off"
}
}
];