-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.eslintrc.js
64 lines (64 loc) · 1.31 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
module.exports = {
parser: 'babel-eslint',
extends: [
'eslint:recommended',
'plugin:jest/recommended',
'plugin:jsx-a11y/recommended'
],
plugins: ['jest', 'react', 'jsx-a11y', 'import', 'prettier', 'codebox'],
env: {
es6: true,
browser: true,
node: true,
jest: true
},
rules: {
indent: ['error', 2],
'linebreak-style': ['error', 'unix'],
semi: ['error', 'always'],
'no-const-assign': 2,
'prefer-spread': 2,
'no-useless-concat': 2,
'no-var': 2,
'object-shorthand': 2,
'prefer-arrow-callback': 2,
'react/jsx-uses-vars': 1,
'react/jsx-uses-react': 1,
'jsx-a11y/label-has-associated-control': 0,
'jsx-a11y/no-autofocus': [
2,
{
ignoreNonDOM: true
}
],
'jsx-a11y/label-has-for': 0,
'codebox/sort-imports': [
'error',
{
groups: [
'builtin',
'external',
'parent',
'sibling',
'index',
['unknown', 'absolute']
],
importTypes: ['default', 'named', 'all', 'none'],
ignoreCase: true
}
],
'codebox/sort-named-imports': [
'error',
{
ignoreCase: true
}
]
},
settings: {
'import/resolver': {
jest: {
jestConfigFile: './jest.config.js'
}
}
}
};