MCPcopy Create free account
hub / github.com/TruthHun/BookStack / toNode

Method toNode

static/katex/katex.mjs:1298–1313  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1296 }
1297
1298 toNode() {
1299 const svgNS = "http://www.w3.org/2000/svg";
1300 const node = document.createElementNS(svgNS, "svg"); // Apply attributes
1301
1302 for (const attr in this.attributes) {
1303 if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
1304 node.setAttribute(attr, this.attributes[attr]);
1305 }
1306 }
1307
1308 for (let i = 0; i < this.children.length; i++) {
1309 node.appendChild(this.children[i].toNode());
1310 }
1311
1312 return node;
1313 }
1314
1315 toMarkup() {
1316 let markup = "<svg"; // Apply attributes

Callers

nothing calls this directly

Calls 2

setAttributeMethod · 0.45
toNodeMethod · 0.45

Tested by

no test coverage detected