⚡️ A better element creation function (
h) for preact
- You want to use preact with no build tool
- You are not in favor of extending the language with non-standard extensions
Why not preact's
Creating and reading dom structures is the bread and butter in creating UI. It should have minimal boilerplate. Thats what this library does - removing boilerplate.
// preact// preact-element
preact-element installed (using your favourite package manager), you can
then import it. Each element
in the DOM is exposed as a function when requiring
const h = // -> h.div()
const div h1 =
const App =
children are optional.