code: function(e) {
      // This is a packet from the wtf.ipc.MessageChannel type.
      var data = e.data;
      if (!data ||
          !data['wtf_ipc_connect_token'] ||
          !data['data']['hello']) {
        return;
      }
  
      // Stop snooping.
      e.preventDefault();
      e.stopPropagation();
      window.removeEventListener('message', waiter, true);
  
      if (opt_callback) {
        opt_callback.call(opt_scope, e.source);
      }
      e.source.focus();
    }
docs: TODO(benvanik): generalize this into an IPC channel