h

@mvuijs/core / h

h #

Const { [key in keyof HTMLElementTagNameMap]: TemplateElementCreator<HTMLElementTagNameMap[key]> } & { custom: typeof fromCustom ; foreach: typeof foreach; fragment: typeof fragment; }

A collection of functions that create a TemplateElement for all standard html elements.

Example #

class Example extends Component {
  render = () => [
    h.div({ attrs: { id: 'hi' }}, h.span('A child <span> element'))
  ]
}

Defined in: packages/core/src/html.ts:20