-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
79 lines (79 loc) · 2.41 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
module.exports = {
env: {
browser: true,
es6: true,
node: true
},
extends: [
'airbnb',
'plugin:import/errors',
'plugin:import/warnings',
'plugin:import/typescript',
'plugin:jest/recommended'
],
globals: {
Atomics: 'readonly',
SharedArrayBuffer: 'readonly'
},
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaFeatures: {
jsx: true
},
ecmaVersion: 2018,
sourceType: 'module'
},
plugins: [
'import',
'react',
'@typescript-eslint',
'jest',
'simple-import-sort',
'unused-imports'
],
rules: {
indent: ['error', 4, { SwitchCase: 1 }],
'react/jsx-indent-props': [1, 4],
semi: ['error', 'never'],
'object-curly-spacing': ['error', 'always'],
'react/jsx-indent': [2, 4],
'react/jsx-filename-extension': [1, { extensions: ['.tsx'] }],
'react/jsx-tag-spacing': ['error', {
closingSlash: 'never',
beforeSelfClosing: 'allow',
afterOpening: 'never',
beforeClosing: 'never'
}],
'no-unused-vars': 'off',
'jsx-a11y/click-events-have-key-events': [0],
'react/no-array-index-key': [1],
'jsx-a11y/no-autofocus': [1],
'jsx-a11y/no-static-element-interactions': [0],
'react/prop-types': [0],
'react/destructuring-assignment': [0, 'never'],
'react/jsx-one-expression-per-line': [0, 'literal'],
'import/prefer-default-export': [0],
'import/extensions': [1, 'never'],
'@typescript-eslint/no-unused-vars': [1, {
vars: 'all',
args: 'after-used',
ignoreRestSiblings: false
}],
'simple-import-sort/sort': 'error',
'unused-imports/no-unused-imports-ts': 'error',
'react/jsx-props-no-spreading': [0],
'import/no-unresolved': [0],
'import/no-extraneous-dependencies': [0],
'import/no-cycle': [0],
'global-require': [0],
'no-else-return': 'off',
'padded-blocks': 'off',
'max-len': [1, 120],
'no-use-before-define': [0],
'arrow-body-style': 'off',
'comma-dangle': 'off',
'no-trailing-spaces': 'off',
'react/jsx-closing-bracket-location': [1, 'after-props'],
'no-useless-constructor': 'off'
}
}