Small (509b) helper function to make working with HTML in JS a little easier.
l(tagname,[props[, ...children]]);import{l}from"lfn.js";// only tagnameconstdiv=l("div");// tag and childrenconstheading=l("h1","hello"," world");// tag and propsconstinput=l("input",{name: "name"});// tag, props and childrenconstbuttons=l("div",{style: "display: flex; "},l("button",{id: "btn_one"}),l("button",{id: "btn_two"}));// orphan tags (rendered as a document fragment)constfragment=l(l("style",` :host { display: block; content: contain; } `),l("div","hello world"));