UNPKG

sandstone-proxy

Version:

An experimental web proxy utilizing sandboxed iframes and no service worker.

11 lines (10 loc) 362 B
import { ctx } from "../context.mjs"; if (typeof MutationObserver !== "undefined") { MutationObserver.prototype.observe = new Proxy(MutationObserver.prototype.observe, { apply: (target, this_arg, args) => { if (args[0] === ctx.document) args[0] = ctx.document.documentElement; return Reflect.apply(target, this_arg, args); } }) }