-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
.eslintrc.cjs
38 lines (35 loc) · 1.12 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
const {getESLintConfig} = require('ocular-dev-tools/configuration');
module.exports = getESLintConfig({
react: '16.8.2',
overrides: {
parserOptions: {
project: ['./tsconfig.json'],
ecmaVersion: 2020
},
rules: {
'max-depth': ['warn', 4],
complexity: ['warn'],
'max-statements': ['warn'],
'callback-return': 0
},
overrides: [
{
files: ['**/*.ts', '**/*.tsx', '**/*.d.ts'],
rules: {
// Gradually enable
'@typescript-eslint/ban-ts-comment': 0,
'@typescript-eslint/ban-types': 0,
'@typescript-eslint/no-unsafe-member-access': 0,
'@typescript-eslint/no-unsafe-assignment': 0,
'import/named': 0,
'@typescript-eslint/no-empty-function': ['warn', {allow: ['arrowFunctions']}],
'@typescript-eslint/restrict-template-expressions': 0,
'@typescript-eslint/explicit-module-boundary-types': 0,
'@typescript-eslint/no-unsafe-return': 0,
'@typescript-eslint/no-unsafe-call': 0,
'@typescript-eslint/restrict-plus-operands': 0
}
}
]
}
});