-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.eslintrc.cjs
53 lines (53 loc) · 1.33 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
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
parserOptions: {
project: './tsconfig.json',
tsconfigRootDir: __dirname,
ecmaVersion: 10,
},
extends: [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:jest/all",
"airbnb-base",
"airbnb-typescript/base",
"prettier"
],
plugins: [
'@typescript-eslint',
'eslint-plugin-tsdoc',
'jest'
],
env: {
es2021: true,
browser: true,
node: true,
jest: true,
},
rules: {
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-use-before-define': 'off',
'import/prefer-default-export': 'off',
'no-console': ["error", { allow: ["warn", "info", "error"] }],
'no-underscore-dangle': 'off',
'no-shadow': 'off',
'no-plusplus': 'off',
'tsdoc/syntax': 'warn',
'arrow-body-style': 'off',
'@typescript-eslint/naming-convention': [
'error',
{
selector: ['variable', 'function'],
format: ['camelCase', 'UPPER_CASE', 'PascalCase'],
trailingUnderscore: 'allow',
},
],
'jest/consistent-test-it': ["error", {"fn": "test", "withinDescribe": "test"}],
"jest/prefer-expect-assertions": [
"warn",
{ "onlyFunctionsWithAsyncKeyword": true }
]
},
};