-
-
Notifications
You must be signed in to change notification settings - Fork 89
/
.jshintrc
188 lines (124 loc) · 5.29 KB
/
.jshintrc
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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
{
"maxerr": "{int} Maximum error before stopping",
"maxerr": 50,
"bitwise": "true: Prohibit bitwise operators (&, |, ^, etc.)",
"bitwise": true,
"camelcase": "true: Identifiers must be in camelCase",
"camelcase": false,
"curly": "true: Require {} for every new block or scope",
"curly": true,
"eqeqeq": "true: Require triple equals (===) for comparison",
"eqeqeq": true,
"forin": "true: Require filtering for..in loops with obj.hasOwnProperty()",
"forin": true,
"immed": "true: Require immediate invocations to be wrapped in parens e.g. `(function () { } ());`",
"immed": true,
"indent": "{int} Number of spaces to use for indentation",
"indent": 4,
"latedef": "true: Require variables/functions to be defined before being used",
"latedef": false,
"newcap": "true: Require capitalization of all constructor functions e.g. `new F()`",
"newcap": true,
"noarg": "true: Prohibit use of `arguments.caller` and `arguments.callee`",
"noarg": true,
"noempty": "true: Prohibit use of empty blocks",
"noempty": true,
"nonew": "true: Prohibit use of constructors for side-effects (without assignment)",
"nonew": false,
"plusplus": "true: Prohibit use of `++` & `--`",
"plusplus": false,
"quotmark": "Quotation mark consistency: false:mixed quotes, true:consistent quotes, 'single':only single quotes, 'double':only double quotes",
"quotmark": false,
"undef": "true: Require all non-global variables to be declared (prevents global leaks)",
"undef": true,
"unused": "true: Require all defined variables be used",
"unused": true,
"strict": "true: Requires all functions run in ES5 Strict Mode",
"strict": true,
"trailing": "true: Prohibit trailing whitespaces",
"trailing": false,
"maxparams": "{int} Max number of formal params allowed per function",
"maxparams": false,
"maxdepth": "{int} Max depth of nested blocks (within functions)",
"maxdepth": false,
"maxstatements": "{int} Max number statements per function",
"maxstatements": false,
"maxcomplexity": "{int} Max cyclomatic complexity per function",
"maxcomplexity": false,
"maxlen": "{int} Max number of characters per line",
"maxlen": false,
"asi": "true: Tolerate Automatic Semicolon Insertion (no semicolons)",
"asi": false,
"boss": "true: Tolerate assignments where comparisons would be expected",
"boss": true,
"debug": "true: Allow debugger statements e.g. browser breakpoints",
"debug": false,
"eqnull": "true: Tolerate use of `== null`",
"eqnull": true,
"es5": "true: Allow ES5 syntax (ex: getters and setters)",
"es5": true,
"esnext": "true: Allow ES.next (ES6) syntax (ex: `const`)",
"esnext": false,
"evil": "true: Tolerate use of `eval` and `new Function()`",
"evil": false,
"expr": "true: Tolerate `ExpressionStatement` as Programs",
"expr": false,
"funcscope": "true: Tolerate defining variables inside control statements",
"funcscope": false,
"globalstrict": "true: Allow global \"use strict\" (also enables 'strict')",
"globalstrict": true,
"iterator": "true: Tolerate using the `__iterator__` property",
"iterator": false,
"lastsemic": "true: Tolerate omitting a semicolon for the last statement of a 1-line block",
"lastsemic": false,
"laxbreak": "true: Tolerate possibly unsafe line breakings",
"laxbreak": false,
"laxcomma": "true: Tolerate comma-first style coding",
"laxcomma": false,
"loopfunc": "true: Tolerate functions being defined in loops",
"loopfunc": false,
"multistr": "true: Tolerate multi-line strings",
"multistr": false,
"proto": "true: Tolerate using the `__proto__` property",
"proto": false,
"scripturl": "true: Tolerate script-targeted URLs",
"scripturl": false,
"smarttabs": "true: Tolerate mixed tabs/spaces when used for alignment",
"smarttabs": false,
"shadow": "true: Allows re-define variables later in code e.g. `var x=1; x=2;`",
"shadow": false,
"sub": "true: Tolerate using `[]` notation when it can still be expressed in dot notation",
"sub": true,
"supernew": "true: Tolerate `new function () { ... };` and `new Object;`",
"supernew": false,
"validthis": "true: Tolerate using this in a non-constructor function",
"validthis": false,
"browser": true,
"couch": false,
"devel": "Development/debugging (alert, confirm, etc)",
"devel": true,
"dojo": false,
"jquery": true,
"mootools": false,
"node": false,
"nonstandard": "Widely adopted globals (escape, unescape, etc)",
"nonstandard": false,
"prototypejs": "Prototype and Scriptaculous",
"prototypejs": false,
"rhino": false,
"worker": "Web Workers",
"worker": false,
"wsh": "Windows Scripting Host",
"wsh": false,
"yui": false,
"nomen": "true: Prohibit dangling `_` in variables",
"nomen": false,
"onevar": "true: Allow only one `var` statement per function",
"onevar": false,
"passfail": "true: Stop on first error",
"passfail": false,
"white": "true: Check against strict whitespace and indentation rules",
"white": false,
"predef": "additional predefined global variables",
"predef": ["angular","describe","it"]
}