How to use the impress.rpc.newtab function in impress

To help you get started, we’ve selected a few impress examples, based on popular ways it is used in public projects.

github metarhia / impress / applications / example / static / js / impress.rpc.js View on Github external
impress.rpc.initializeConnection = function() {
    if (!impress.rpc.initialized) {
      impress.rpc.tabId = impress.rpc.getFreeTab();
      impress.rpc.tabKey = 'impress.rpc.tab' + impress.rpc.tabId;
      impress.rpc.heartbeat();
      impress.rpc.heartbeatEvent = setInterval(impress.rpc.heartbeat, impress.rpc.heartbeatInterval);
      localStorage['impress.rpc.newtab'] = impress.rpc.tabId;
      global.addEventListener('storage', impress.rpc.onStorageChange, false);
    }
    var master = localStorage['impress.rpc.master'];
    if (master) impress.rpc.setMaster(master);
    else impress.rpc.createMaster();
    impress.rpc.initializeDone();
  };

impress

Enterprise application server for Node.js

MIT
Latest version published 1 month ago

Package Health Score

82 / 100
Full package analysis

Similar packages