uniScore/public/js/back_client.js

18 lines
310 B
JavaScript
Raw Normal View History

2017-03-14 15:02:54 +00:00
'use strict';
// This is the backend client js
let iosocket: object = io.connect();
// setup all my handlers
iosocket.on('clientrefresh', () => {
location.reload();
});
iosocket.on('stateChange', () => {
2017-03-16 09:41:51 +00:00
2017-03-14 15:02:54 +00:00
location.reload();
});
// get my state
let context = 'admin';
iosocket.emit('loadState',context);