forked from microsoft/vscode-jshint
-
Notifications
You must be signed in to change notification settings - Fork 0
/
package.json
553 lines (553 loc) · 16.1 KB
/
package.json
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
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
{
"name": "jshint",
"description": "Integrates JSHint into VS Code. JSHint is a linter for JavaScript",
"version": "0.11.0",
"author": "Microsoft Corporation",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/Microsoft/vscode-jshint.git"
},
"bugs": {
"url": "https://github.com/Microsoft/vscode-jshint/issues"
},
"icon": "jshint_icon.png",
"galleryBanner": {
"color": "#5c2d91",
"theme": "dark"
},
"categories": [
"Linters"
],
"publisher": "dbaeumer",
"engines": {
"vscode": "^1.26.0"
},
"activationEvents": [
"onLanguage:javascript",
"onLanguage:javascriptreact",
"onLanguage:html",
"onCommand:jshint.resetLibraryExecutions",
"onCommand:jshint.showOutputChannel"
],
"main": "./jshint/out/extension",
"contributes": {
"configuration": {
"type": "object",
"title": "JSHint configuration",
"properties": {
"jshint.enable": {
"type": "boolean",
"default": true,
"description": "Control whether or not jshint is enabled for JavaScript files."
},
"jshint.config": {
"type": [
"string",
"null"
],
"default": null,
"description": "A path to file containing the configuration options for jshint. If the file exists it overrides jshint.options and any .jshintrc file"
},
"jshint.options": {
"type": "object",
"properties": {
"bitwise": {
"description": "Prohibit the use of bitwise operators (&, |, ^, etc.)",
"type": "boolean",
"default": false
},
"curly": {
"description": "Requires you to always put curly braces around blocks in loops and conditionals",
"type": "boolean",
"default": false
},
"eqeqeq": {
"description": "Prohibits the use of `==` and `!=` in favor of `===` and `!==`",
"type": "boolean",
"default": false
},
"esversion": {
"description": "The ECMAScript version to which the code must adhere",
"type": "integer",
"default": 5,
"enum": [
3,
5,
6,
7,
8,
9
]
},
"forin": {
"description": "Requires all `for in` loops to filter object's items with obj.hasOwnProperty()",
"type": "boolean",
"default": false
},
"freeze": {
"description": "Prohibits overwriting prototypes of native objects such as Array, Date and so on",
"type": "boolean",
"default": false
},
"funcscope": {
"description": "Suppresses warnings about declaring variables inside of control structures while accessing them later from the outside",
"type": "boolean",
"default": false
},
"futurehostile": {
"description": "Enables warnings about the use of identifiers which are defined in future versions of JavaScript",
"type": "boolean",
"default": false
},
"iterator": {
"description": "Suppresses warnings about the __iterator__ property.",
"type": "boolean",
"default": false
},
"latedef": {
"description": "Prohibits the use of a variable before it was defined",
"enum": [
true,
false,
"nofunc"
],
"default": false
},
"leanswitch": {
"description": "Prohibits unnecessary clauses within `switch` statements",
"type": "boolean",
"default": false
},
"maxcomplexity": {
"description": "Max cyclomatic complexity per function",
"type": [
"boolean",
"integer"
],
"default": false
},
"maxdepth": {
"description": "Max depth of nested blocks",
"type": [
"boolean",
"integer"
],
"default": false
},
"maxerr": {
"description": "Maximum amount of warnings JSHint will produce before giving up",
"type": "integer",
"default": 50
},
"maxparams": {
"description": "Max number of formal parameters allowed per function",
"type": [
"boolean",
"integer"
]
},
"maxstatements": {
"description": "Max number statements per function",
"type": [
"boolean",
"integer"
],
"default": false
},
"noarg": {
"description": "Prohibits the use of `arguments.caller` and `arguments.callee`",
"type": "boolean",
"default": false
},
"nocomma": {
"description": "Prohibits the use of the comma operator",
"type": "boolean",
"default": false
},
"nonbsp": {
"description": "Warns about `non-breaking whitespace` characters",
"type": "boolean",
"default": false
},
"nonew": {
"description": "Prohibits the use of constructors for side-effects (without assignment)",
"type": "boolean",
"default": false
},
"notypeof": {
"description": "Suppresses warnings about invalid `typeof`operator values",
"type": "boolean",
"default": false
},
"noreturnawait": {
"description": "Async functions resolve on their return value. In most cases, this makes returning the result of an AwaitExpression (which is itself a Promise instance) unnecessary",
"type": "boolean",
"default": false
},
"regexpu": {
"description": "Enables warnings for regular rexpressions which do not include the 'u' flag",
"type": "boolean",
"default": false
},
"shadow": {
"description": "Suppresses warnings about variable shadowing. i.e. declaring a variable that had been already declared somewhere in the outer scope",
"type": [
"boolean",
"string"
],
"default": false,
"enum": [
true,
false,
"inner",
"outer"
]
},
"singleGroups": {
"description": "Prohibits the use of the grouping operator when it is not strictly required.",
"type": "boolean",
"default": false
},
"strict": {
"description": "Requires all code to run in ES5 strict mode",
"type": [
"boolean",
"string"
],
"default": false,
"enum": [
true,
false,
"implied",
"global",
"func"
]
},
"trailingcomma": {
"description": "Warns when a comma is not placed after the last element in an array or object literal",
"type": "boolean",
"default": false
},
"undef": {
"description": "Prohibits the use of explicitly undeclared variables",
"type": "boolean",
"default": false
},
"unused": {
"description": "Warns when you define and never use your variables",
"type": [
"boolean",
"string"
],
"default": false,
"enum": [
true,
false,
"vars",
"strict"
]
},
"varstmt": {
"description": "Forbids the use of VariableStatements (`var`) in favor of `let` and `const`",
"type": "boolean",
"default": false
},
"asi": {
"description": "Suppresses warnings about missing semicolons",
"type": "boolean",
"default": false
},
"boss": {
"description": "Suppresses warnings about the use of assignments in cases where comparisons are expected",
"type": "boolean",
"default": false
},
"debug": {
"description": "Suppresses warnings about the `debugger` statements in your code",
"type": "boolean",
"default": false
},
"elision": {
"description": "Tells JSHint that your code uses ES3 array elision elements, or empty elements",
"type": "boolean",
"default": false
},
"eqnull": {
"description": "Suppresses warnings about `== null` comparisons",
"type": "boolean",
"default": false
},
"evil": {
"description": "Suppresses warnings about the use of `eval`",
"type": "boolean",
"default": false
},
"expr": {
"description": "Suppresses warnings about the use of expressions where normally you would expect to see assignments or function calls",
"type": "boolean",
"default": false
},
"lastsemic": {
"description": "Suppresses warnings about missing semicolons, but only when the semicolon is omitted for the last statement in a one-line block",
"type": "boolean",
"default": false
},
"loopfunc": {
"description": "Suppresses warnings about functions inside of loops",
"type": "boolean",
"default": false
},
"moz": {
"description": "Tells JSHint that your code uses Mozilla JavaScript extensions",
"type": "boolean",
"default": false
},
"noyield": {
"description": "Suppresses warnings about generator functions with no `yield` statement in them",
"type": "boolean",
"default": false
},
"plusplus": {
"description": "Prohibits the use of `++` and `--`",
"type": "boolean",
"default": false
},
"proto": {
"description": "Suppresses warnings about the `__proto__` property",
"type": "boolean",
"default": false
},
"scripturl": {
"description": "Suppresses warnings about the use of script-targeted URLs",
"type": "boolean",
"default": false
},
"supernew": {
"description": "Suppresses warnings about constructions like `new function () { ... };` and `new Object;`",
"type": "boolean",
"default": false
},
"validthis": {
"description": "Suppresses warnings about possible strict violations when the code is running in strict mode and you use `this` in a non-constructor function",
"type": "boolean",
"default": false
},
"withstmt": {
"description": "Suppresses warnings about the use of the `with` statement",
"type": "boolean",
"default": false
},
"browser": {
"description": "[Environment] Web Browser (window, document, etc)",
"type": "boolean",
"default": false
},
"browserify": {
"description": "[Environment] Browserify",
"type": "boolean",
"default": false
},
"couch": {
"description": "[Environment] CouchDB",
"type": "boolean",
"default": false
},
"devel": {
"description": "[Environment] Development/debugging (alert, confirm, etc)",
"type": "boolean",
"default": false
},
"dojo": {
"description": "[Environment] Dojo Toolkit",
"type": "boolean",
"default": false
},
"jasmine": {
"description": "[Environment] Jasmine unit testing framework",
"type": "boolean",
"default": false
},
"jquery": {
"description": "[Environment] jQuery",
"type": "boolean",
"default": false
},
"mocha": {
"description": "[Environment] Mocha unit testing framework",
"type": "boolean",
"default": false
},
"module": {
"description": "[Environment] ES6 module",
"type": "boolean",
"default": false
},
"mootools": {
"description": "[Environment] MooTools",
"type": "boolean",
"default": false
},
"node": {
"description": "[Environment] Node.js",
"type": "boolean",
"default": false
},
"nonstandard": {
"description": "[Environment] Widely adopted globals (escape, unescape, etc)",
"type": "boolean",
"default": false
},
"phantom": {
"description": "[Environment] PhantomJS runtime environment",
"type": "boolean",
"default": false
},
"prototypejs": {
"description": "[Environment] Prototype JavaScript framework",
"type": "boolean",
"default": false
},
"rhino": {
"description": "[Environment] Rhino",
"type": "boolean",
"default": false
},
"shelljs": {
"description": "[Environment] Defines globals exposed by the ShellJS library",
"type": "boolean",
"default": false
},
"typed": {
"description": "[Environment] Defines globals for typed array constructors",
"type": "boolean",
"default": false
},
"worker": {
"description": "[Environment] Web Workers",
"type": "boolean",
"default": false
},
"wsh": {
"description": "[Environment] Windows Scripting Host",
"type": "boolean",
"default": false
},
"yui": {
"description": "[Environment] Yahoo User Interface",
"type": "boolean",
"default": false
},
"globals": {
"description": "Specify a white list of global variables that are not formally defined in the source code",
"type": "object",
"additionalProperties": {
"description": "Name of the global. Set to `true` for read/write, `false` for read-only.",
"type": "boolean"
}
},
"extends": {
"description": "Specify the path to another configuration file to use as a base, relative to the current file",
"type": "string"
},
"overrides": {
"description": "Specify the options that should only be applied to files matching a given path pattern",
"type": "object",
"additionalProperties": {
"description": "The path pattern to apply the given options to",
"type": "object"
}
}
},
"default": {},
"description": "The jshint options object to provide args to the jshint command."
},
"jshint.excludePath": {
"type": [
"string",
"null"
],
"default": null,
"description": "A path to a file containing patterns describing which files and directories should be ignored by jshint. If the file exists it overrides jshint.exclude and any .jshintignore file."
},
"jshint.exclude": {
"type": "object",
"default": {},
"description": "Matching files and directories are being ignored by jshint. Glob patterns are interpreted relative to the workspace's root folder."
},
"jshint.reportWarningsAsErrors": {
"type": "boolean",
"default": false,
"description": "Report warnings as errors"
},
"jshint.lintHTML": {
"type": "boolean",
"default": false,
"description": "Lint JavaScript embedded in HTML"
},
"jshint.nodePath": {
"scope": "resource",
"type": "string",
"default": "",
"description": "Configures the path to the jshint module. Can be an absolute path or relative to the current directory."
},
"jshint.packageManager": {
"scope": "resource",
"type": "string",
"enum": [
"npm",
"yarn"
],
"default": "npm",
"description": "The package manager you use to install node modules."
},
"jshint.trace.server": {
"scope": "window",
"type": "string",
"enum": [
"off",
"messages",
"verbose"
],
"default": "off",
"description": "Traces the communication between VS Code and the jshint linter service."
}
}
},
"commands": [
{
"title": "Show output",
"category": "JSHint",
"command": "jshint.showOutputChannel"
},
{
"title": "Reset Library Execution Decisions",
"category": "JSHint",
"command": "jshint.resetLibraryExecutions"
}
],
"jsonValidation": [
{
"fileMatch": "jshint.json",
"url": "http://json.schemastore.org/grunt-jshint-task"
},
{
"fileMatch": ".jshintrc",
"url": "http://json.schemastore.org/jshintrc"
}
]
},
"scripts": {
"vscode:prepublish": "npm run compile",
"compile:client": "tsc -p jshint/tsconfig.json",
"compile:server": "tsc -p jshint-server/tsconfig.json",
"watch:client": "tsc -w -p jshint/tsconfig.json",
"watch:server": "tsc -w -p jshint-server/tsconfig.json",
"compile": "npm run compile:client && npm run compile:server",
"postinstall": "cd jshint && npm install && cd ../jshint-server && npm install && cd .."
},
"devDependencies": {
"typescript": "^2.6.2",
"@types/node": "^9.4.0"
}
}