-
Notifications
You must be signed in to change notification settings - Fork 49
Expand file tree
/
Copy patheslint.config.mjs
More file actions
39 lines (36 loc) · 1.18 KB
/
eslint.config.mjs
File metadata and controls
39 lines (36 loc) · 1.18 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
import js from "@eslint/js";
import globals from "globals";
import tsParser from "@typescript-eslint/parser";
import tsPlugin from "@typescript-eslint/eslint-plugin";
import { defineConfig } from "eslint/config";
const avaPlugin = await import("eslint-plugin-ava");
export default defineConfig([
js.configs.recommended,
{
files: ["src/**/*.ts", "tests/**/*.ts"],
languageOptions: {
parser: tsParser,
parserOptions: {
project: "./tsconfig.json",
tsconfigRootDir: process.cwd(),
},
sourceType: "module",
globals: {
...globals.node,
},
},
plugins: {
"@typescript-eslint": tsPlugin,
ava: avaPlugin.default,
},
rules: {
"@typescript-eslint/no-explicit-any": "warn",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": ["error", { argsIgnorePattern: "^_" }],
"@typescript-eslint/explicit-module-boundary-types": "off",
"no-console": "off",
"ava/no-only-test": "error",
"ava/no-skip-test": "warn",
},
},
]);