-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
97 lines (97 loc) · 2.44 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
module.exports = {
parser: '@typescript-eslint/parser',
extends: [
'plugin:prettier/recommended',
'plugin:react/recommended',
'airbnb',
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/eslint-recommended'
],
parserOptions: {
ecmaVersion: 2018,
sourceType: 'module'
},
plugins: ['react-hooks', '@typescript-eslint', 'prettier', 'react'],
rules: {
'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': 'warn',
'react/jsx-props-no-spreading': 'off',
'react/jsx-filename-extension': 'off',
'react/jsx-wrap-multilines': [
1,
{
assignment: 'parens-new-line'
}
],
'react/require-default-props': 'off',
'react/jsx-uses-react': 'off',
'react/react-in-jsx-scope': 'off',
'react/prop-types': ['off'],
'react/function-component-definition': [
2,
{
namedComponents: 'arrow-function',
unnamedComponents: 'arrow-function'
}
],
'import/extensions': 'off',
'import/no-unresolved': 'error',
'import/no-extraneous-dependencies': 'off',
'import/prefer-default-export': 'off',
'import/order': [
1,
{
groups: [['external', 'builtin'], 'type', 'internal', 'sibling', 'parent', 'index'],
pathGroups: [
{
pattern: 'components|hooks|helpers|utils|store|types|constants|contexts|api',
group: 'internal'
}
],
pathGroupsExcludedImportTypes: ['internal'],
alphabetize: {
order: 'asc',
caseInsensitive: true
},
'newlines-between': 'always'
}
],
'no-param-reassign': [
2,
{
props: false
}
],
'arrow-parens': ['error', 'always'],
'object-curly-newline': [
'error',
{
consistent: true,
multiline: true
}
],
'no-case-declarations': 'off',
'no-control-regex': 'off',
'implicit-arrow-linebreak': 'off',
semi: 'off',
'quote-props': [2, 'as-needed'],
'comma-dangle': 'off',
'linebreak-style': 'off',
'function-paren-newline': 'off',
indent: 'off',
'no-undef': 'off',
'no-multi-spaces': 'off',
'operator-linebreak': 'off',
'max-len': 'off',
'no-shadow': 'off',
'@typescript-eslint/no-shadow': ['error']
},
settings: {
'import/resolver': {
node: {
paths: ['src'],
extensions: ['.js', '.jsx', '.ts', '.tsx']
}
}
}
}