-
Notifications
You must be signed in to change notification settings - Fork 297
Expand file tree
/
Copy patheslint.config.mjs
More file actions
54 lines (53 loc) · 1.29 KB
/
Copy patheslint.config.mjs
File metadata and controls
54 lines (53 loc) · 1.29 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
import eslint from "@eslint/js";
import { defineConfig } from "eslint/config";
import tseslint from "typescript-eslint";
import vitest from "@vitest/eslint-plugin";
import globals from "globals";
export default defineConfig(
eslint.configs.recommended,
tseslint.configs.recommendedTypeChecked,
{
languageOptions: {
parserOptions: {
projectService: true,
tsconfigRootDir: import.meta.dirname,
},
},
},
{
languageOptions: {
globals: {
...globals.node,
...vitest.environments.env.globals,
},
},
},
{
files: ["**/*.js", "**/*.mjs", "**/*.cjs"],
extends: [tseslint.configs.disableTypeChecked],
rules: {
"@typescript-eslint/no-require-imports": "off",
},
},
{
rules: {
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/no-unused-vars": "off",
"prefer-const": "off",
"no-useless-escape": "off",
"no-empty": "off",
// https://github.com/plopjs/plop/issues/288
"linebreak-style": ["error", "unix"],
},
},
{
ignores: [
".yarn",
"**/instrumented/**/*",
"**/tests/examples/**/*",
"**/plop-templates/**/*",
],
},
);