Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
appendTo(selector: string) {
let element = assertElement(document.querySelector(selector) as SimpleElement);
let self = new UpdatableRootReference(this);
let cursor = { element, nextSibling: null };
let handle = unwrapTemplate(this.template)
.asLayout()
.compile(this.syntax);
let templateIterator = renderJitMain(
this.runtime,
this.syntax,
self,
clientBuilder(this.runtime.env, cursor),
unwrapHandle(handle)
);
let result;
do {
result = templateIterator.next();
} while (!result.done);
this.element = firstElementChild(element)!;
}
}
getElementBuilder(env: Environment, cursor: Cursor): ElementBuilder {
return clientBuilder(env, cursor);
}
getElementBuilder(env: Environment, cursor: Cursor): ElementBuilder {
return clientBuilder(env, cursor);
}
getElementBuilder(env: Environment, cursor: Cursor): MutElementBuilder {
return clientBuilder(env, cursor);
}
getBuilder(env: Environment): ElementBuilder {
return clientBuilder(env, this.cursor);
}
}