-
Notifications
You must be signed in to change notification settings - Fork 5
/
.eslintrc.js
43 lines (37 loc) · 1.17 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
module.exports = {
extends: 'react-app',
parser: 'babel-eslint',
rules: {
// https://github.com/airbnb/javascript#commas--dangling
'comma-dangle': ['warn', 'always-multiline'],
// Objects
// https://github.com/airbnb/javascript#objects--no-new
'no-new-object': 'warn',
// Semicolons:
'no-extra-semi': 'warn',
// https://github.com/airbnb/javascript#semicolons--required
semi: ['warn', 'always'],
'semi-spacing': ['warn', { before: false, after: true }],
// Vars:
'no-var': 'warn',
'prefer-const': ['warn', {
destructuring: 'any',
ignoreReadBeforeAssign: true,
}],
'one-var': ['warn', 'never'],
'one-var-declaration-per-line': ['warn', 'always'],
// https://github.com/airbnb/javascript#comparison--switch-blocks
'no-case-declarations': 'warn',
// PropTypes:
'react/prop-types': ['warn', { ignore: [], customValidators: [] }],
'react/no-unused-prop-types': ['warn', {
customValidators: [
],
skipShapeProps: true,
}],
// Imports:
'import/first': ['warn', 'absolute-first'],
// https://github.com/airbnb/javascript#coercion--numbers
radix: 'warn',
},
};