MCPcopy Create free account
hub / github.com/chhoumann/quickadd / getOwnerWindow

Function getOwnerWindow

src/utils/activeWindow.ts:12–18  ·  view source on GitHub ↗
(node: Node)

Source from the content-addressed store, hash-verified

10}
11
12export function getOwnerWindow(node: Node): Window {
13 const ownerWindow = getOwnerDocument(node).defaultView;
14 if (!ownerWindow) {
15 throw new Error("Unable to resolve owner window for DOM node.");
16 }
17 return ownerWindow;
18}
19
20export function createOwnedElement<K extends keyof HTMLElementTagNameMap>(
21 owner: Node,

Callers 3

showNoResultsAndCloseFunction · 0.90
openFunction · 0.90
closeFunction · 0.90

Calls 1

getOwnerDocumentFunction · 0.70

Tested by

no test coverage detected