Inline rendering with document.currentScript
27 points by carlana
27 points by carlana
Reminder: If using innerHTML or outerHTML, sanitise the HTML first, especially if you fetched it externally!
Or just use setHTML :)
Cool trick! Love to see fellow human who still enjoys cute code in this age!
I really like the counter example. It's close in abstraction to how code in a "modern", component based js framework would look like, but much lighter and built in.