-
Notifications
You must be signed in to change notification settings - Fork 22
/
Copy path.eslintrc.js
38 lines (38 loc) · 1.11 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
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
parserOptions: {
tsconfigRootDir: __dirname,
project: ['./tsconfig.json', './packages/*/tsconfig.json', './packages/*/*/tsconfig.json'],
},
plugins: ['@typescript-eslint', 'react-hooks', 'eslint-plugin-tsdoc', 'eslint-plugin-react'],
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/recommended-requiring-type-checking',
],
rules: {
'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': 'warn',
'react/self-closing-comp': 'error',
'prefer-template': 'error',
'tsdoc/syntax': 'warn',
'@typescript-eslint/ban-ts-comment': 'off',
// '@typescript-eslint/no-unsafe-assignment': 'warn',
// '@typescript-eslint/no-unsafe-member-access': 'warn',
// '@typescript-eslint/no-unsafe-call': 'warn',
},
env: {
browser: true,
node: true,
},
overrides: [
{
files: ["*.cjs"],
rules: {
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/no-unsafe-assignment": "off"
}
}
]
};