-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
65 lines (65 loc) · 1.9 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
module.exports = {
env: {
es6: true,
node: true
},
extends: 'eslint:recommended',
parserOptions: {
ecmaVersion: 7,
sourceType: 'module',
ecmaFeatures: {
jsx: true,
experimentalObjectRestSpread: true,
}
},
plugins: [
'react'
],
rules: {
'indent': ['error', 2],
'quotes': ['error', 'single'],
'linebreak-style': ['error', 'unix'],
'semi': ['error', 'never'],
'comma-dangle': ['warn', 'always-multiline'],
'constructor-super': 'error',
'no-confusing-arrow': 'error',
'no-constant-condition': 'error',
'no-class-assign': 'error',
'no-const-assign': 'error',
'no-dupe-class-members': 'error',
'no-var': 'warn',
'no-this-before-super': 'error',
'object-shorthand': ['error', 'always'],
'prefer-spread': 'warn',
'prefer-template': 'warn',
'require-yield': 'error',
'jsx-quotes': 'warn',
'react/forbid-prop-types': 'warn',
'react/jsx-boolean-value': 'warn',
'react/jsx-closing-bracket-location': 'warn',
'react/jsx-curly-spacing': 'warn',
'react/jsx-indent-props': 'warn',
'react/jsx-max-props-per-line': 'warn',
'react/jsx-no-bind': 'warn',
'react/jsx-no-duplicate-props': 'warn',
'react/jsx-no-undef': 'warn',
'react/sort-prop-types': 'warn',
'react/jsx-sort-props': 'warn',
'react/jsx-uses-react': 'warn',
'react/jsx-uses-vars': 'warn',
'react/no-danger': 'warn',
'react/no-did-mount-set-state': 'warn',
'react/no-did-update-set-state': 'warn',
'react/no-direct-mutation-state': 'warn',
'react/no-multi-comp': 'warn',
'react/no-set-state': 'warn',
'react/no-unknown-property': 'warn',
'react/prefer-es6-class': 'warn',
'react/prop-types': 'warn',
'react/react-in-jsx-scope': 'warn',
'react/require-extension': 'warn',
'react/self-closing-comp': 'warn',
'react/sort-comp': 'warn',
'react/wrap-multilines': 'warn'
}
}