forked from jslint-org/jslint
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjslint.html
440 lines (412 loc) · 10.4 KB
/
jslint.html
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
<!DOCTYPE html>
<html><head>
<meta charset="utf-8" />
<meta
name="description"
content="JSLint, The JavaScript Code Quality Tool. This file allows JSLint
to be run from a web browser. It can accept a source program and analyze it
without sending it over the network."
/>
<meta
name="author"
content="Douglas Crockford"
/>
<meta
name="date"
content="2017-12-26"
/>
<title>JSLint: The JavaScript Code Quality Tool</title>
<link
rel="stylesheet"
type="text/css"
href="http://fonts.googleapis.com/css?family=Patua+One"
/>
<link
rel="icon"
href="image/favicon.ico"
/>
<style>
@font-face {
font-family: 'Programma';
font-weight: normal;
src: url('Programma-Regular.woff') format('woff');
}
body {
background-color: antiquewhite;
color: black;
font-family: 'Patua One', monospace;
margin: 0;
padding: 0;
}
#JSLINT_TITLE {
color: darkslategray;
float: left;
font-family: 'Patua One', monospace;
font-size: 48pt;
margin: 0;
margin-left: 0.5%;
padding: 0;
transform: rotate(-17deg);
}
#JSLINT_ fieldset {
background-color: gainsboro;
border: 0;
clear: both;
margin-bottom: 1em;
margin-left: 3%;
margin-right: 3%;
margin-top: 1em;
padding: 0;
width: auto;
}
#JSLINT_ legend {
background-color: darkslategray;
border: 0;
color: white;
font-size: 100%;
font-style: normal;
font-weight: normal;
margin: 0;
padding-bottom: 0.25em;
padding-left: 0;
padding-right: 0;
padding-top: 0.25em;
text-align: center;
width: 100%;
}
#JSLINT_ button {
background-color: darkslategray;
border: 0;
color: white;
cursor: pointer;
font-family: 'Patua One', serif;
font-size: 100%;
font-style: normal;
margin-left: 1em;
margin-right: 1em;
padding-left: 1em;
padding-right: 1em;
text-align: center;
}
#JSLINT_ button:hover {
background-color: slategray;
color: white;
border: 0;
}
#JSLINT_ button:active {
border: 0;
color: black;
}
#JSLINT_ button:disabled {
background-color: gray;
border: 0;
color: gainsboro;
}
a:visited {
color: #69565c;
}
a:link {
color: black;
}
#JSLINT_ input[type="text"] {
background-color: white;
border: 0;
color: black;
margin-bottom: 0.2em;
margin-right: 0.5em;
padding-left: 0.5em;
padding-right: 0.5em;
text-align: right;
width: 3em;
}
#JSLINT_ textarea {
border: 0;
background-color: white;
border: 0;
font-family: Programma, monospace;
font-weight: normal;
font-size: 90%;
resize: none;
}
#JSLINT_ textarea::selection {
background-color: yellow;
color: black;
}
#JSLINT_NUMBER {
color: darkgray;
display: inline-block;
height: 4in;
margin: 2%;
margin-right: 0;
overflow: hidden;
padding-right: 0.5%;
text-align: right;
white-space: pre;
width: 4%;
}
#JSLINT_SOURCE {
color: black;
display: inline-block;
height: 4in;
margin: 2%;
margin-left: 0;
margin-right: 0;
overflow: auto;
padding-left: 0.5%;
white-space: pre;
width: 91%;
}
#JSLINT_PROPERTY {
background-color: honeydew;
border: 0;
margin: 2%;
padding: 0.5%;
white-space: pre;
width: 95%;
}
#JSLINT_GLOBAL {
white-space: normal;
width: 95%;
}
#JSLINT_ label {
font-family: sans-serif;
font-size: 90%;
padding-left: 0.25em;
}
#JSLINT_OPTIONS>div {
float: left;
margin: 0.5em;
}
#JSLINT_ address {
color: black;
display: block;
float: right;
font-family: serif;
font-size: 90%;
margin-left: 1em;
}
#JSLINT_ dl {
background-color: cornsilk;
color: white;
margin: 0;
padding-bottom: 2pt;
padding-left: 1em;
padding-right: 1em;
padding-top: 2pt;
}
#JSLINT_ dfn {
color: black;
display: block;
font-family: monospace;
font-size: 100%;
font-style: normal;
font-weight: normal;
margin-bottom: 2pt;
}
#JSLINT_ dt {
color: black;
display: block;
float: left;
font-family: serif;
font-size: 75%;
font-style: italic;
margin: 0;
width: 8em;
text-align: right;
}
#JSLINT_ dd {
color: black;
display: block;
font-family: monospace;
margin-left: 8em;
padding-bottom: 2pt;
}
#JSLINT_WARNINGS>legend {
background-color: indianred;
}
#JSLINT_WARNINGS>div {
background-color: pink;
padding: 1em;
}
#JSLINT_WARNINGS cite {
color: black;
display: block;
font-family: serif;
font-size: 100%;
font-style: normal;
margin-bottom: 4pt;
margin-left: 20pt;
margin-right: 20pt;
margin-top: 4pt;
overflow-x: hidden;
}
#JSLINT_WARNINGS samp {
background-color: lavenderblush;
color: black;
display: block;
font-family: monospace;
font-size: 100%;
font-style: normal;
padding: 4pt;
margin-bottom: 0;
margin-left: 16pt;
margin-right: 16pt;
margin-top: 0;
white-space: pre-wrap;
}
#JSLINT_REPORT center {
margin-top: 0.5em;
margin-bottom: 0.5em;
}
#JSLINT_WARNINGS dl address {
color: black;
display: inline;
float: none;
font-size: 80%;
margin: 0;
}
#JSLINT_REPORT>div {
padding: 1em;
}
#JSLINT_ dl.level0 {
color: black;
background-color: white;
}
#JSLINT_ dl.level1 {
color: black;
background-color: #ffffe0; /* yellow */
margin-left: 1em;
}
#JSLINT_ dl.level2 {
color: black;
background-color: #e0ffe0; /* green */
margin-left: 2em;
}
#JSLINT_ dl.level3 {
color: black;
background-color: #e0e0ff; /* blue */
margin-left: 3em;
}
#JSLINT_ dl.level4 {
background-color: #ffe0ff; /* purple */
color: black;
margin-left: 4em;
}
#JSLINT_ dl.level5 {
background-color: #ffe0e0; /* red */
color: black;
margin-left: 5em;
}
#JSLINT_ dl.level6 {
background-color: #ffe390; /* orange */
color: black;
margin-left: 6em;
}
#JSLINT_ dl.level7 {
background-color: #e0e0e0; /* gray */
color: black;
margin-left: 7em;
}
#JSLINT_ dl.level8 {
color: black;
margin-left: 8em;
}
#JSLINT_ dl.level9 {
color: black;
margin-left: 9em;
}
</style>
<script src="jslint.js"></script>
<script src="adsafe.js"></script>
<script src="report.js"></script>
</head>
<body><div id="JSLINT_TITLE">J<u>SLint</u></div>
<div id="JSLINT_">
<div style="float: left; margin-bottom: 1em; margin-left: 2em;">
</div>
<ul style="float: right; margin: 1em; padding-right: 1em;">
<li><a href="help.html">Read the instructions.</a></li>
<li><a
href="http://www.amazon.com/exec/obidos/ASIN/0596517742/wrrrldwideweb"
target="_blank"
>Read <i>The Good Parts</i>.</a></li>
</ul>
<fieldset><legend>Source</legend>
<textarea id="JSLINT_NUMBER" rows="18" readonly=true></textarea><textarea
id="JSLINT_SOURCE" rows="18" autofocus spellcheck="false"
placeholder="// Paste JavaScript source or JSON text here."></textarea>
</fieldset>
<div style="text-align: center;">
<button name=JSLint>J<u>SLint</u></button>
<button name=clear>clear</button>
</div>
<fieldset id=JSLINT_WARNINGS style="display: none;"><legend>Warnings</legend><div></div>
</fieldset>
<fieldset id=JSLINT_REPORT style="display: none;">
<legend>Function Report</legend>
<div></div>
</fieldset>
<fieldset id=JSLINT_PROPERTYFIELDSET style="display: none;">
<legend>Property Directive</legend>
<textarea id=JSLINT_PROPERTY rows="8" readonly=true></textarea>
</fieldset>
<div id=JSLINT_AUX style="display: none; text-align: center;">
<button name=select id=JSLINT_SELECT>select property</button>
<button name=JSLint>J<u>SLint</u></button>
<button name=clear>clear</button>
<button name=options>clear options</button>
</div>
<fieldset id=JSLINT_OPTIONS><legend>Options</legend>
<div>Assume...
<div><label><input title=devel type=checkbox>in development</label></div>
<div><label><input title=browser type=checkbox>a browser</label></div>
<div><label><input title=couch type=checkbox>CouchDB</label></div>
<div><label><input title=node type=checkbox>Node.js</label></div>
<br>Fudge...
<div><label><input id="JSLINT_FUDGE" title=fudge type=checkbox>First line number is 1</label></div>
</div>
<div>Tolerate...
<div><label><input title=bitwise type=checkbox>bitwise operators</label></div>
<div><label><input title=convert type=checkbox>conversion operators</label></div>
<div><label><input title=eval type=checkbox>eval</label></div>
<div><label><input title=for type=checkbox>for statement</label></div>
<div><label><input title=getset type=checkbox>get and set</label></div>
<div><label><input title=multivar type=checkbox>multiple vars</label></div>
<div><label><input title=single type=checkbox>single quote strings</label></div>
<div><label><input title=this type=checkbox>this</label></div>
<div><label><input title=white type=checkbox>whitespace mess</label></div>
</div>
<div>Number...
<div><label><input type=text title=maxlen>Maximum line length</label></div>
<div><label><input type=text title=maxerr>Maximum warnings</label></div>
</div>
<div>Global variables...
<textarea
id=JSLINT_GLOBAL
title=global
spellcheck="false"
placeholder="imported globals here"
></textarea>
</div>
</fieldset>
<script>
ADSAFE.id("JSLINT_");
</script>
<script src="browser.js"></script>
<script>
ADSAFE.go("JSLINT_", function (dom, lib) {
"use strict";
lib.browser_ui(dom);
});
</script>
</div>
<center>
<a href="http://www.JSLint.com/"><img src="image/jslintpill.gif" width="36" height="17" border="0"></a>
<a href="https://github.com/douglascrockford/JSLint"><img src="image/github.gif" width="39" height="16" border="0"></a>
<a href="https://plus.google.com/communities/104441363299760713736"><img src="image/gpill.gif" width="36" height="17" border="0"></a>
<a href="http://www.JSON.org/"><img src="image/jsonpill.gif" width="36" height="17" border="0"></a>
<a href="http://www.ADsafe.org/"><img src="image/adsafepill.gif" width="36" height="17" border="0"></a>
<a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=RDLHY5MSG3LZW"><img src="image/pppill.gif" width="36" height="17" border="0"></a>
<a href="http://www.1and1.com/?k_id=10219574"><img src="image/1and1pill.gif" width="36" height="17" border="0"></a>
</center>
</body></html>