forked from remy/jsconsole
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
55 lines (48 loc) · 2.48 KB
/
index.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
<!DOCTYPE html>
<html lang="en" manifest="jsconsole.appcache">
<head>
<meta charset="utf-8" />
<title>JavaScript console - for debugging JavaScript and remote debugging mobile web apps</title>
<meta id="meta" name="viewport" content="width=device-width, user-scalable=no, initial-scale=1" />
<!--
Hey there fellow JavaScript lover - I assume you've got a soft spot
for the JavaScript, otherwise what use would a console be to you?
This was primarily built out of a demo I wrote for my upcoming book
introducinghtml5.com as a way to introspect what was going on inside
a web worker, since the environment is sandboxed. Then I realised,
I need a sandbox environment/console that I could increase the font
size - and having seen something similar-ish by @thomasfuchs, I went
about tweaking my worker demo to this. About 3 hours work one late
Sunday afternoon.
The way this works, is I generate an iframe on the fly, an run the
commands through an eval *inside* the iframe, so it's a fairly good
enviroment to run tests. Then I've got a custom stringify function
because JSON.stringify doesn't decode native DOM objects, like the
DOMWindow object.
There's more I want to do with this, so watch the github account
or even contribute: http://github.com/remy/jsconsole
Otherwise, hope you enjoy this app. Any questions or issues, drop
me a message on github or Twitter: http://twitter.com/rem
- Cheers, @rem
-->
<link rel="icon" href="/favicon.png" type="image/png">
<link rel='apple-touch-icon' href='/favicon.png' />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<link href="/startup.png" rel="apple-touch-startup-image" />
<link rel="stylesheet" href="console.css" />
</head>
<body>
<form>
<textarea autofocus id="exec" spellcheck="false" autocapitalize="off" rows="1" autocorrect="off"></textarea>
</form>
<div id="console">
<ul id="output"></ul>
</div>
<div id="footer"><a href="/app/">Get the native iOS app</a> • <a href="http://github.com/remy/jsconsole">Fork on Github</a> • <a href="http://twitter.com/rem">Built by @rem</a></div>
<script src="prettify.packed.js"></script>
<script src="EventSource.js"></script>
<script src="console.js"></script>
<script>var _gaq=[['_setAccount','UA-1656750-21'],['_trackPageview']];(function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0];g.src='//www.google-analytics.com/ga.js';s.parentNode.insertBefore(g,s)})(document,'script')</script>
</body>
</html>