async-debug 0.1.1 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (98) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.sig +0 -0
  3. data/lib/async/debug/application.rb +21 -0
  4. data/lib/async/debug/reactor_view.rb +7 -24
  5. data/lib/async/debug/version.rb +3 -20
  6. data/lib/async/debug.rb +15 -71
  7. data/license.md +21 -0
  8. data/readme.md +27 -0
  9. data.tar.gz.sig +0 -0
  10. metadata +45 -182
  11. metadata.gz.sig +0 -0
  12. data/pages/_heading.xnode +0 -2
  13. data/pages/_page.xnode +0 -42
  14. data/pages/controller.rb +0 -19
  15. data/pages/errors/exception.xnode +0 -5
  16. data/pages/errors/file-not-found.xnode +0 -5
  17. data/pages/index.xnode +0 -3
  18. data/pages/links.yaml +0 -4
  19. data/public/_components/@socketry/live/live.js +0 -157
  20. data/public/_components/@socketry/live/live.min.js +0 -1
  21. data/public/_components/jquery/jquery.js +0 -10872
  22. data/public/_components/jquery/jquery.min.js +0 -2
  23. data/public/_components/jquery/jquery.min.map +0 -1
  24. data/public/_components/jquery/jquery.slim.js +0 -8777
  25. data/public/_components/jquery/jquery.slim.min.js +0 -2
  26. data/public/_components/jquery/jquery.slim.min.map +0 -1
  27. data/public/_components/jquery-syntax/base/jquery.syntax.brush.apache.css +0 -12
  28. data/public/_components/jquery-syntax/base/jquery.syntax.brush.applescript.css +0 -5
  29. data/public/_components/jquery-syntax/base/jquery.syntax.brush.assembly.css +0 -8
  30. data/public/_components/jquery-syntax/base/jquery.syntax.brush.bash-script.css +0 -4
  31. data/public/_components/jquery-syntax/base/jquery.syntax.brush.bash.css +0 -2
  32. data/public/_components/jquery-syntax/base/jquery.syntax.brush.clang.css +0 -6
  33. data/public/_components/jquery-syntax/base/jquery.syntax.brush.css.css +0 -14
  34. data/public/_components/jquery-syntax/base/jquery.syntax.brush.diff.css +0 -16
  35. data/public/_components/jquery-syntax/base/jquery.syntax.brush.html.css +0 -5
  36. data/public/_components/jquery-syntax/base/jquery.syntax.brush.ocaml.css +0 -3
  37. data/public/_components/jquery-syntax/base/jquery.syntax.brush.protobuf.css +0 -2
  38. data/public/_components/jquery-syntax/base/jquery.syntax.brush.python.css +0 -6
  39. data/public/_components/jquery-syntax/base/jquery.syntax.brush.ruby.css +0 -2
  40. data/public/_components/jquery-syntax/base/jquery.syntax.brush.xml.css +0 -35
  41. data/public/_components/jquery-syntax/base/jquery.syntax.core.css +0 -58
  42. data/public/_components/jquery-syntax/base/jquery.syntax.editor.css +0 -6
  43. data/public/_components/jquery-syntax/base/theme.js +0 -1
  44. data/public/_components/jquery-syntax/bright/jquery.syntax.core.css +0 -27
  45. data/public/_components/jquery-syntax/bright/theme.js +0 -1
  46. data/public/_components/jquery-syntax/jquery.syntax.brush.apache.js +0 -3
  47. data/public/_components/jquery-syntax/jquery.syntax.brush.applescript.js +0 -5
  48. data/public/_components/jquery-syntax/jquery.syntax.brush.assembly.js +0 -3
  49. data/public/_components/jquery-syntax/jquery.syntax.brush.bash-script.js +0 -4
  50. data/public/_components/jquery-syntax/jquery.syntax.brush.bash.js +0 -2
  51. data/public/_components/jquery-syntax/jquery.syntax.brush.basic.js +0 -5
  52. data/public/_components/jquery-syntax/jquery.syntax.brush.clang.js +0 -5
  53. data/public/_components/jquery-syntax/jquery.syntax.brush.csharp.js +0 -4
  54. data/public/_components/jquery-syntax/jquery.syntax.brush.css.js +0 -5
  55. data/public/_components/jquery-syntax/jquery.syntax.brush.diff.js +0 -2
  56. data/public/_components/jquery-syntax/jquery.syntax.brush.go.js +0 -3
  57. data/public/_components/jquery-syntax/jquery.syntax.brush.haskell.js +0 -3
  58. data/public/_components/jquery-syntax/jquery.syntax.brush.html.js +0 -4
  59. data/public/_components/jquery-syntax/jquery.syntax.brush.io.js +0 -3
  60. data/public/_components/jquery-syntax/jquery.syntax.brush.java.js +0 -4
  61. data/public/_components/jquery-syntax/jquery.syntax.brush.javascript.js +0 -3
  62. data/public/_components/jquery-syntax/jquery.syntax.brush.kai.js +0 -2
  63. data/public/_components/jquery-syntax/jquery.syntax.brush.lisp.js +0 -2
  64. data/public/_components/jquery-syntax/jquery.syntax.brush.lua.js +0 -3
  65. data/public/_components/jquery-syntax/jquery.syntax.brush.nginx.js +0 -2
  66. data/public/_components/jquery-syntax/jquery.syntax.brush.ocaml.js +0 -4
  67. data/public/_components/jquery-syntax/jquery.syntax.brush.ooc.js +0 -4
  68. data/public/_components/jquery-syntax/jquery.syntax.brush.pascal.js +0 -4
  69. data/public/_components/jquery-syntax/jquery.syntax.brush.perl5.js +0 -3
  70. data/public/_components/jquery-syntax/jquery.syntax.brush.php-script.js +0 -4
  71. data/public/_components/jquery-syntax/jquery.syntax.brush.php.js +0 -2
  72. data/public/_components/jquery-syntax/jquery.syntax.brush.plain.js +0 -2
  73. data/public/_components/jquery-syntax/jquery.syntax.brush.protobuf.js +0 -3
  74. data/public/_components/jquery-syntax/jquery.syntax.brush.python.js +0 -5
  75. data/public/_components/jquery-syntax/jquery.syntax.brush.ruby.js +0 -5
  76. data/public/_components/jquery-syntax/jquery.syntax.brush.scala.js +0 -4
  77. data/public/_components/jquery-syntax/jquery.syntax.brush.smalltalk.js +0 -2
  78. data/public/_components/jquery-syntax/jquery.syntax.brush.sql.js +0 -4
  79. data/public/_components/jquery-syntax/jquery.syntax.brush.super-collider.js +0 -3
  80. data/public/_components/jquery-syntax/jquery.syntax.brush.swift.js +0 -3
  81. data/public/_components/jquery-syntax/jquery.syntax.brush.trenni.js +0 -2
  82. data/public/_components/jquery-syntax/jquery.syntax.brush.xml.js +0 -4
  83. data/public/_components/jquery-syntax/jquery.syntax.brush.yaml.js +0 -2
  84. data/public/_components/jquery-syntax/jquery.syntax.cache.js +0 -7
  85. data/public/_components/jquery-syntax/jquery.syntax.core.js +0 -34
  86. data/public/_components/jquery-syntax/jquery.syntax.editor.js +0 -11
  87. data/public/_components/jquery-syntax/jquery.syntax.js +0 -8
  88. data/public/_components/jquery-syntax/jquery.syntax.min.js +0 -13
  89. data/public/_components/jquery-syntax/paper/jquery.syntax.core.css +0 -31
  90. data/public/_components/jquery-syntax/paper/theme.js +0 -1
  91. data/public/_components/morphdom/morphdom-esm.js +0 -755
  92. data/public/_components/morphdom/morphdom-factory.js +0 -691
  93. data/public/_components/morphdom/morphdom-umd.js +0 -763
  94. data/public/_components/morphdom/morphdom-umd.min.js +0 -1
  95. data/public/_components/morphdom/morphdom.js +0 -757
  96. data/public/_static/icon.png +0 -0
  97. data/public/_static/links.js +0 -21
  98. /data/public/_static/{site.css → index.css} +0 -0
@@ -1,157 +0,0 @@
1
- var live = (function () {
2
- 'use strict';
3
-
4
- class Live {
5
- constructor(document, url) {
6
- this.document = document;
7
-
8
- this.url = url;
9
- this.events = [];
10
-
11
- this.failures = 0;
12
-
13
- // Track visibility state and connect if required:
14
- this.document.addEventListener("visibilitychange", () => this.handleVisibilityChange());
15
- this.handleVisibilityChange();
16
- }
17
-
18
- connect() {
19
- if (this.server) return;
20
-
21
- let server = this.server = new WebSocket(this.url.href);
22
-
23
- server.onopen = () => {
24
- this.failures = 0;
25
- this.attach();
26
- };
27
-
28
- server.onmessage = (message) => {
29
- const [name, _arguments] = JSON.parse(message.data);
30
-
31
- this[name](..._arguments);
32
- };
33
-
34
- server.onerror = () => {
35
- this.failures += 1;
36
- };
37
-
38
- // The remote end has disconnected:
39
- server.onclose = () => {
40
- this.server = null;
41
-
42
- // We need a minimum delay otherwise this can end up immediately invoking the callback:
43
- let delay = 100 * (this.failures + 1) ** 2;
44
- setTimeout(() => this.connect(), delay > 60000 ? 60000 : delay);
45
- };
46
- }
47
-
48
- disconnect() {
49
- if (this.server) {
50
- this.server.close();
51
- this.server = null;
52
- }
53
- }
54
-
55
- createDocumentFragment(html) {
56
- return this.document.createRange().createContextualFragment(html);
57
- }
58
-
59
- // These methods are designed for RPC.
60
- replace(id, html) {
61
- let element = document.getElementById(id);
62
-
63
- morphdom(element, html);
64
- }
65
-
66
- prepend(id, html) {
67
- let element = document.getElementById(id);
68
- let fragment = this.createDocumentFragment(html);
69
-
70
- element.prepend(fragment);
71
- }
72
-
73
- append(id, html) {
74
- let element = document.getElementById(id);
75
- let fragment = this.createDocumentFragment(html);
76
-
77
- element.append(fragment);
78
- }
79
-
80
- dispatch(id, type, details) {
81
- let element = document.getElementById(id);
82
-
83
- element.dispatchEvent(
84
- new CustomEvent(type, details)
85
- );
86
- }
87
-
88
- trigger(id, event) {
89
- this.connect();
90
-
91
- this.send(
92
- JSON.stringify({id: id, event: event})
93
- );
94
- }
95
-
96
- forward(id, event, details) {
97
- this.trigger(id, {type: event.type, details: details});
98
- }
99
-
100
- send(message) {
101
- try {
102
- this.server.send(message);
103
- } catch (error) {
104
- this.events.push(message);
105
- }
106
- }
107
-
108
- flush() {
109
- if (this.events.length === 0) return;
110
-
111
- let events = this.events;
112
- this.events = [];
113
-
114
- for (var event of events) {
115
- this.send(event);
116
- }
117
- }
118
-
119
- bind(elements) {
120
- for (var element of elements) {
121
- this.send(JSON.stringify({bind: element.id, data: element.dataset}));
122
- }
123
- }
124
-
125
- bindElementsByClassName(selector = 'live') {
126
- this.bind(
127
- this.document.getElementsByClassName(selector)
128
- );
129
-
130
- this.flush();
131
- }
132
-
133
- handleVisibilityChange() {
134
- if (document.hidden) {
135
- this.disconnect();
136
- } else {
137
- this.connect();
138
- }
139
- }
140
-
141
- attach() {
142
- if (this.document.readyState === 'loading') {
143
- this.document.addEventListener('DOMContentLoaded', () => this.bindElementsByClassName());
144
- } else {
145
- this.bindElementsByClassName();
146
- }
147
- }
148
- }
149
-
150
- let url = new URL('live', location.href);
151
- url.protocol = url.protocol.replace('http', 'ws');
152
-
153
- let live = new Live(document, url);
154
-
155
- return live;
156
-
157
- }());
@@ -1 +0,0 @@
1
- var live=function(){"use strict";class Live{constructor(document,url){this.document=document;this.url=url;this.events=[];this.failures=0;this.document.addEventListener("visibilitychange",()=>this.handleVisibilityChange());this.handleVisibilityChange()}connect(){if(this.server)return;let server=this.server=new WebSocket(this.url.href);server.onopen=()=>{this.failures=0;this.attach()};server.onmessage=message=>{const[name,_arguments]=JSON.parse(message.data);this[name](..._arguments)};server.onerror=()=>{this.failures+=1};server.onclose=()=>{this.server=null;let delay=100*(this.failures+1)**2;setTimeout(()=>this.connect(),delay>6e4?6e4:delay)}}disconnect(){if(this.server){this.server.close();this.server=null}}createDocumentFragment(html){return this.document.createRange().createContextualFragment(html)}replace(id,html){let element=document.getElementById(id);morphdom(element,html)}prepend(id,html){let element=document.getElementById(id);let fragment=this.createDocumentFragment(html);element.prepend(fragment)}append(id,html){let element=document.getElementById(id);let fragment=this.createDocumentFragment(html);element.append(fragment)}dispatch(id,type,details){let element=document.getElementById(id);element.dispatchEvent(new CustomEvent(type,details))}trigger(id,event){this.connect();this.send(JSON.stringify({id:id,event:event}))}forward(id,event,details){this.trigger(id,{type:event.type,details:details})}send(message){try{this.server.send(message)}catch(error){this.events.push(message)}}flush(){if(this.events.length===0)return;let events=this.events;this.events=[];for(var event of events){this.send(event)}}bind(elements){for(var element of elements){this.send(JSON.stringify({bind:element.id,data:element.dataset}))}}bindElementsByClassName(selector="live"){this.bind(this.document.getElementsByClassName(selector));this.flush()}handleVisibilityChange(){if(document.hidden){this.disconnect()}else{this.connect()}}attach(){if(this.document.readyState==="loading"){this.document.addEventListener("DOMContentLoaded",()=>this.bindElementsByClassName())}else{this.bindElementsByClassName()}}}let url=new URL("live",location.href);url.protocol=url.protocol.replace("http","ws");let live=new Live(document,url);return live}();