MCPcopy Create free account
hub / github.com/bigskysoftware/_hyperscript / morph

Method morph

www/js/_hyperscript.esm.js:2471–2483  ·  view source on GitHub ↗
(elt, content)

Source from the content-addressed store, hash-verified

2469 this.reactivity.notifyProperty(obj);
2470 }
2471 morph(elt, content) {
2472 this.#morphEngine.morph(elt, content, {
2473 beforeNodeRemoved: (node) => {
2474 if (node.nodeType === 1) this.cleanup(node);
2475 },
2476 afterNodeAdded: (node) => {
2477 if (node.nodeType === 1) this.processNode(node);
2478 },
2479 afterNodeMorphed: (node) => {
2480 if (node.nodeType === 1) this.processNode(node);
2481 }
2482 });
2483 }
2484 replaceInDom(target, value) {
2485 this.implicitLoop(target, (elt) => {
2486 var parent = elt.parentElement;

Callers

nothing calls this directly

Calls 3

cleanupMethod · 0.95
processNodeMethod · 0.95
morphMethod · 0.45

Tested by

no test coverage detected