-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy path.eslintrc.js
73 lines (72 loc) · 2 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
const { resolve } = require('path');
module.exports = {
parser: 'babel-eslint',
parserOptions: {
sourceType: 'module',
allowImportExportEverywhere: true
},
extends: 'airbnb',
env: {
'jest/globals': true,
browser: true,
node: true
},
rules: {
semi: 'off',
"flowtype/define-flow-type": 1,
"flowtype/use-flow-type": 1,
'arrow-parens': ['off'],
'compat/compat': 'error',
'comma-dangle': 'off',
'consistent-return': 'off',
'generator-star-spacing': 'off',
'import/order': ['error', { 'newlines-between': 'always' }],
'import/no-unresolved': 'error', // # hack until resolving import properly
'import/extensions': 'error', // # hack until resolving import properly
'import/no-extraneous-dependencies': 'off',
'jsx-a11y/anchor-is-valid': 'off',
'jsx-a11y/click-events-have-key-events': 0,
'jsx-a11y/no-static-element-interactions': 0,
'jsx-a11y/label-has-for': 0,
'jsx-a11y/no-autofocus': 0,
'linebreak-style': 'off',
'no-console': 'off',
'no-use-before-define': 'off',
'no-multi-assign': 'off',
'no-plusplus': 'off',
'no-loop-func': 'off',
'promise/param-names': 'error',
'promise/always-return': 'error',
'promise/catch-or-return': 'error',
'promise/no-native': 'off',
'react/no-array-index-key': 0,
'react/sort-comp': [
'error',
{
order: [
'type-annotations',
'static-methods',
'lifecycle',
'everything-else',
'render'
]
}
],
'react/jsx-no-bind': 'off',
'react/jsx-one-expression-per-line': 'off',
'react/jsx-filename-extension': ['error', { extensions: ['.js', '.jsx'] }],
'react/prefer-stateless-function': 'off'
},
plugins: ['jest', 'flowtype', 'import', 'promise', 'compat', 'react'],
settings: {
'import/resolver': {
node: {
paths: [
resolve(__dirname),
resolve(__dirname, 'app', 'vendor'),
'node_modules'
]
}
}
}
};