forked from firefox-devtools/profiler
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
104 lines (103 loc) · 3.26 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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
module.exports = {
"env": {
"browser": true,
"es6": true,
"node": true
},
"parser": "babel-eslint",
"extends": ["eslint:recommended", "plugin:react/recommended"],
"parserOptions": {
"ecmaFeatures": {
"experimentalObjectRestSpread": true,
"jsx": true
},
"sourceType": "module"
},
"plugins": [
"react",
"flowtype"
],
"rules": {
// Flow type rules:
"flowtype/define-flow-type": 1,
"flowtype/use-flow-type": 1,
"flowtype/generic-spacing": [2, "never"],
"flowtype/space-before-type-colon": [ 2, "never" ],
"flowtype/space-after-type-colon": [ 2, "always" ],
// JS Rules:
"indent": [
"error",
2,
{ "SwitchCase": 1 }
],
"linebreak-style": [ "error", "unix" ],
"quotes": [ "error", "single" ],
"semi": [ "error", "always" ],
"no-extra-semi": "error",
"comma-dangle": [ "error", "always-multiline" ],
"no-console": [ "error", { allow: ["log", "warn", "error"] } ],
"eqeqeq": "error",
"consistent-return": "error",
"curly": ["error", "all" ],
"dot-location": ["error", "property"],
"dot-notation": "error",
"no-alert": "error",
"no-caller": "error",
"no-else-return": "error",
"no-eval": "error",
"no-implied-eval": "error",
"no-extend-native": "error",
"no-native-reassign": "error",
"no-extra-bind": "error",
"no-labels": "error",
"no-implicit-globals": "error",
"no-invalid-this": "error",
"no-iterator": "error",
"no-lone-blocks": "error",
"no-loop-func": "error",
"no-multi-spaces": "error",
"no-param-reassign": "error",
"no-proto": "error",
"no-return-assign": "error",
"no-script-url": "error",
"no-self-compare": "error",
"no-throw-literal": "error",
"no-unmodified-loop-condition": "error",
"no-unused-expressions": "error",
"no-useless-concat": "error",
"no-useless-escape": "error",
"no-void": "error",
"no-with": "error",
"radix": "error",
"yoda": ["error", "never", { "exceptRange": true }],
"brace-style": ["error", "1tbs", { "allowSingleLine": true }],
"camelcase": "error",
"comma-spacing": "error",
"comma-style": "error",
"jsx-quotes": ["error", "prefer-single"],
"key-spacing": "error",
"keyword-spacing": "error",
"no-new-object": "error",
"no-spaced-func": "error",
"semi-spacing": "error",
"space-in-parens": ["error", "never"],
"spaced-comment": "error",
"generator-star-spacing": "error",
"no-duplicate-imports": "error",
"no-var": "error",
"prefer-const": "error",
"array-bracket-spacing": "error",
"space-before-function-paren": ["error", {
"anonymous": "always",
"named": "never",
"asyncArrow": "always",
}],
"arrow-parens": ["error", "as-needed"],
},
"settings": {
"react": {
"pragma": "React",
"version": "15.0"
}
}
};