-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.cjs
56 lines (55 loc) · 1.46 KB
/
.eslintrc.cjs
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
const path = require('path');
module.exports = {
env: {
browser: false,
es2021: true,
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
overrides: [],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 'latest',
project: path.resolve(__dirname, 'headless/tsconfig.json'),
sourceType: 'module',
tsconfigRootDir: path.resolve(__dirname, 'headless'),
},
plugins: ['@typescript-eslint'],
rules: {
"no-console": "warn",
'@typescript-eslint/explicit-module-boundary-types': 0,
'@typescript-eslint/no-explicit-any': 0,
'@typescript-eslint/ban-types': 0,
'@typescript-eslint/no-unused-vars': 2,
'@typescript-eslint/no-non-null-assertion': 2,
'@typescript-eslint/no-empty-function': 2,
'@typescript-eslint/prefer-nullish-coalescing': 1,
'@typescript-eslint/prefer-optional-chain': 1,
'@typescript-eslint/no-misused-promises': 0,
'@typescript-eslint/no-floating-promises': 1,
'@typescript-eslint/no-var-requires': 1,
'eol-last': 2,
'max-len': [
'error',
{
code: 80,
ignoreComments: true,
ignoreUrls: true,
ignoreStrings: true,
ignoreTemplateLiterals: true,
},
],
'no-trailing-spaces': 'error',
quotes: [
2,
'single',
{
avoidEscape: true,
allowTemplateLiterals: true,
},
],
},
};