-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.js
More file actions
40 lines (39 loc) · 1.38 KB
/
Copy patheslint.config.js
File metadata and controls
40 lines (39 loc) · 1.38 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
const { defineConfig, globalIgnores } = require("eslint/config");
const globals = require("globals");
const tseslint = require("@typescript-eslint/eslint-plugin");
const tsparser = require("@typescript-eslint/parser");
const importPlugin = require("eslint-plugin-import");
const nPlugin = require("eslint-plugin-n");
const promisePlugin = require("eslint-plugin-promise");
module.exports = defineConfig([
{
files: ["**/*.ts"],
languageOptions: {
globals: {
...globals.browser,
...globals.node,
},
ecmaVersion: "latest",
sourceType: "module",
parser: tsparser,
parserOptions: {
project: "./tsconfig.spec.json",
},
},
plugins: {
"@typescript-eslint": tseslint,
import: importPlugin,
n: nPlugin,
promise: promisePlugin,
},
rules: {
strict: 1,
"@typescript-eslint/semi": ["off"],
"@typescript-eslint/no-var-requires": ["off"],
"@typescript-eslint/no-floating-promises": ["off"],
"@typescript-eslint/strict-boolean-expressions": ["off"],
"@typescript-eslint/explicit-function-return-type": ["off"],
},
},
globalIgnores(["**/*.config.js", "**/.eslintrc.js", "dist/", "coverage/", "node_modules/"]),
]);