-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
60 lines (60 loc) · 1.68 KB
/
.eslintrc.js
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
57
58
59
60
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
plugins: [
'@typescript-eslint',
'security',
],
extends: [
'eslint:recommended',
'airbnb-base',
'plugin:@typescript-eslint/recommended',
'plugin:security/recommended',
],
settings: {
'import/resolver': {
typescript: {},
},
},
rules: {
'max-len': ['error', {
code: 140,
tabWidth: 2,
ignoreTrailingComments: true,
ignoreComments: true,
}],
'consistent-return': 'off',
'no-nested-ternary': 'off',
'no-plusplus': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'no-use-before-define': 'off',
'@typescript-eslint/no-use-before-define': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
// disable some rules from parents to avoid problems
'import/extensions': [
'error',
'ignorePackages',
{
js: 'never',
jsx: 'never',
ts: 'never',
tsx: 'never',
},
],
'no-underscore-dangle': ['error', { allow: ['_id'] }],
'arrow-parens': ['error', 'as-needed'],
'import/prefer-default-export': 'off',
'object-curly-newline': 'off',
'object-property-newline': ['error', { allowAllPropertiesOnSameLine: false }],
'no-param-reassign': 'off',
'security/detect-non-literal-fs-filename': 'off',
'import/order': 'off',
'no-useless-constructor': 'off',
'@typescript-eslint/no-useless-constructor': ['error'],
'security/detect-object-injection': 'off',
'security/detect-non-literal-regexp': 'off',
'class-methods-use-this': 'off',
'camelcase': 'off',
},
};