MCPcopy Index your code
hub / github.com/bigskysoftware/_hyperscript / processNode

Method processNode

www/js/_hyperscript.esm.js:2880–2895  ·  view source on GitHub ↗
(elt)

Source from the content-addressed store, hash-verified

2878 this.#afterProcessHooks.push(fn);
2879 }
2880 processNode(elt) {
2881 for (var fn of this.#beforeProcessHooks) fn(elt);
2882 var selector = this.#getScriptSelector();
2883 if (this.matchesSelector(elt, selector)) {
2884 this.#initElement(elt, elt);
2885 }
2886 if (elt instanceof HTMLScriptElement && elt.type === "text/hyperscript") {
2887 this.#initElement(elt, document.body);
2888 }
2889 if (elt.querySelectorAll) {
2890 this.forEach(elt.querySelectorAll(selector + ", [type='text/hyperscript']"), (elt2) => {
2891 this.#initElement(elt2, elt2 instanceof HTMLScriptElement && elt2.type === "text/hyperscript" ? document.body : elt2);
2892 });
2893 }
2894 for (var fn of this.#afterProcessHooks) fn(elt);
2895 }
2896 // =================================================================
2897 // Debug and tracing
2898 // =================================================================

Callers 8

morphMethod · 0.95
replaceInDomMethod · 0.95
resolveMethod · 0.45
putIntoMethod · 0.45
resolveMethod · 0.45
initLiveTemplatesFunction · 0.45
stampFunction · 0.45

Calls 5

#getScriptSelectorMethod · 0.95
matchesSelectorMethod · 0.95
#initElementMethod · 0.95
forEachMethod · 0.95
fnFunction · 0.85

Tested by

no test coverage detected