2 ms·
err... no? Example using Lit and Template Literals: html`<div class="thing-contents">Hello</div>`; Example using only web components: shadow.innerHTML =
by meiraleal 2y ago
err... no?
Example using Lit and Template Literals:
html`<div class="thing-contents">Hello</div>`;
Example using only web components:
shadow.innerHTML = `<div class="thing-contents">Hello</div>`;
- rvense 2y agoRight, JSX is not the only way of accomplishing a better syntax for dynamic HTML. I was just saying that I do occasionally do things entirely by hand in Javascript with createElement, and it works for a quick thing but it is actually definitely a thing that warrents bringing in some alternative.