-
Notifications
You must be signed in to change notification settings - Fork 4
/
.eslintrc.yml
79 lines (69 loc) · 1.74 KB
/
.eslintrc.yml
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
# see http://eslint.org/docs/rules/ for recommended rules
extends: 'eslint:recommended'
rules:
indent:
- 2
- 4
- SwitchCase: 1
linebreak-style: [2, unix]
no-console: [0]
no-unused-vars: [1]
# commas go last
comma-style: [1, last]
# variable comes before literal in conditional
yoda: [1, never]
# dots on same line as property
dot-location: [1, property]
# don't allow void operator
no-void: [1]
# no space before function paren
space-before-function-paren: [1, never]
# prefer a single declaration for vars
one-var:
- 1
space-before-blocks: [1, always]
# prefer no space between array brackets
array-bracket-spacing: [1, never]
# prefer no space between object curly brackets
object-curly-spacing: [1, never]
# prefer no space between object prop brackets
computed-property-spacing: [1, never]
# prefer camelcase
# camelcase:
# - 1
# - properties: always
# prefer brackets for blocks
curly: [1]
no-multi-spaces: [1]
space-in-parens: [1, never]
eol-last: [1]
no-trailing-spaces: [1]
no-mixed-spaces-and-tabs: [1]
# Allow but do not force dangling commas.
comma-dangle: [0]
# use single quotes
quotes: [2, single]
# use semicolons to end statements
semi: [2, always]
# warn if function params are reassigned
no-param-reassign:
- 1
- props: false
# enforce type equality
eqeqeq: [2]
no-return-assign: [2, always]
no-undef-init: [1]
no-lonely-if: [2]
no-use-before-define: [2, nofunc]
# enforce constructor functions are uppercased
new-cap:
- 2
- newIsCap: true
capIsNew: false
env:
# allow node env globals
node: true
# allow commonjs module definition globals (e.g. require, module.exports)
commonjs: true
es6: true
globals: