aboutsummaryrefslogtreecommitdiffstats
path: root/web/src/js
diff options
context:
space:
mode:
Diffstat (limited to 'web/src/js')
-rw-r--r--web/src/js/connection.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/web/src/js/connection.js b/web/src/js/connection.js
index 0a74ed33..a4369b5a 100644
--- a/web/src/js/connection.js
+++ b/web/src/js/connection.js
@@ -18,7 +18,15 @@ _Connection.prototype.onopen = function (open) {
};
_Connection.prototype.onmessage = function (message) {
//AppDispatcher.dispatchServerAction(...);
- console.log("onmessage", this, arguments);
+ var m = JSON.parse(message.data);
+ switch (m.type){
+ case "flow":
+ console.log("flow", m.data);
+ break;
+ case "event":
+ console.log("event", m.data.message)
+ break;
+ }
};
_Connection.prototype.onerror = function (error) {
console.log("onerror", this, arguments);