-
Notifications
You must be signed in to change notification settings - Fork 11
/
.eslintrc
43 lines (34 loc) · 1.06 KB
/
.eslintrc
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
{
"extends": ["airbnb"],
"parser": "babel-eslint",
"plugins": ["react"],
"rules": {
// Disable trailing comma
"comma-dangle": ["error", "never"],
"import/no-extraneous-dependencies": "off",
// Use indent with 4 spaces
"indent": ["error", 4, {
"VariableDeclarator": {
"var": 2,
"let": 2,
"const": 2
},
"SwitchCase": 1
}],
// Deprecated
"jsx-a11y/href-no-hash": "off",
// Use single quote in jsx attributes
"jsx-quotes": ["error", "prefer-single"],
"no-use-before-define": "off",
// Use indent with 4 spaces for jsx
"react/jsx-indent": ["error", 4],
// Use indent with 4 spaces in props
"react/jsx-indent-props": ["error", 4],
// Allow .js & .jsx extension
"react/jsx-filename-extension": ["error", {
"extensions": [".js", ".jsx"]
}],
// Enforce component methods order
"react/sort-comp": "off"
}
}