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

Function createElementWithAttributes

src/core/dom/index.js:171–174  ·  view source on GitHub ↗
(doc, tagName, attributes)

Source from the content-addressed store, hash-verified

169 * @return {Element} created element
170 */
171export function createElementWithAttributes(doc, tagName, attributes) {
172 const element = doc.createElement(tagName);
173 return addAttributesToElement(element, attributes);
174}
175
176/**
177 * Returns true if node is connected (attached).

Callers 15

test-amp-pixel.jsFile · 0.90
createAmpElementFunction · 0.90
test-scheduler.jsFile · 0.90
insertElementFunction · 0.90
test-navigation.jsFile · 0.90
test-builders.jsFile · 0.90

Calls 1

addAttributesToElementFunction · 0.70

Tested by

no test coverage detected