export declare function reframedDomInsertion(nodeToInsert: T, doInsertTheNode: Function, iframeDocument?: Document): T; export declare function executeScriptsInPiercedFragment(shadowRoot: ShadowRoot, iframe: HTMLIFrameElement): void; /** * Weak map of scripts running in the iframe to their inert clones in the reframed DOM. */ export declare const execToInertScriptMap: WeakMap; export declare const alreadyExecutedScriptsAndLinks: WeakSet; /** * Executes a script in a reframed JS context. * @param inertScript inert script already appended to a document within reframed DOM * @param iframeDocument iframe document in which the script should execute. * @returns true if the script executed, false if it was ignored */ export declare function executeInertScript(inertScript: HTMLScriptElement, iframeDocument: Document): boolean; export declare function executeInertPreloadLink(inertLink: HTMLLinkElement, iframeDocument: Document): boolean; /** * Attaches exec scripts to iframe and keeps a record of already evaluated scripts * @param inertScript inert script already appended to a document within reframed DOM * @param execScript exec script to be attached to the iframe document. * @param iframeDocument iframe document in which the script should execute. */ export declare function attachScriptsToIframe({ inertScript, execScript, iframeDocument, }: { inertScript: HTMLScriptElement; execScript?: HTMLScriptElement; iframeDocument: Document; }): void;