MCPcopy
hub / github.com/ampproject/amphtml / copyElementToChildWindow

Function copyElementToChildWindow

src/service/custom-element-registry.js:158–161  ·  view source on GitHub ↗
(parentWin, childWin, name)

Source from the content-addressed store, hash-verified

156 * @param {string} name
157 */
158export function copyElementToChildWindow(parentWin, childWin, name) {
159 const toClass = getExtendedElements(parentWin)[name];
160 registerElement(childWin, name, toClass || ElementStub);
161}
162
163/**
164 * Registers a new custom element with its implementation class.

Calls 2

getExtendedElementsFunction · 0.85
registerElementFunction · 0.85

Tested by

no test coverage detected