mirror of
https://github.com/MercuryWorkshop/scramjet.git
synced 2025-05-13 14:30:02 -04:00
properly rewrite postmessage
This commit is contained in:
parent
34c3cc5094
commit
c2d147442e
9 changed files with 134 additions and 17 deletions
|
@ -2,6 +2,16 @@
|
|||
|
||||
import { ScramjetClient } from "./client";
|
||||
|
||||
export const iswindow = "window" in self;
|
||||
export const isworker = "WorkerGlobalScope" in self;
|
||||
export const issw = "ServiceWorkerGlobalScope" in self;
|
||||
export const isdedicated = "DedicatedWorkerGlobalScope" in self;
|
||||
export const isshared = "SharedWorkerGlobalScope" in self;
|
||||
|
||||
export const wrapfn = "$scramjet$wrap";
|
||||
export const trysetfn = "$scramjet$tryset";
|
||||
export const importfn = "$scramjet$import";
|
||||
|
||||
dbg.log("scrammin");
|
||||
// if it already exists, that means the handlers have probably already been setup by the parent document
|
||||
if (!(ScramjetClient.SCRAMJET in self)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue