Skip to content
Portfolio

HTM UI

Accessible Preact and htm components shipped as native ES modules — no build step, no JSX, no bundler.

View project →

HTM UI is a component set for Preact and htm. Files are native ES modules. A page loads them with an import map or from a CDN. There is no JSX compile step and no bundler in the default path.

The APIs and tokens stay close to the shadcn/ui ecosystem. The implementation, catalog, and identity are HTM UI’s own.

HTM UI docs, with live buttons, a chart, and the component registry

How a page uses it

import { html } from "htm/preact";
import { Button } from "htm-ui/button.js";

function App() {
  return html`<${Button} variant="outline">Click me<//>`;
}

The per-file path (htm-ui/button.js) is the documented API. A barrel index.js also exports the set for a single import. Styling is Tailwind CSS v4, with cn() for class merging and Iconify for icons.

The docs app previews the registry in the browser: djalmajr.github.io/htm-ui. An agent skill in the same repo covers component choice, theming, and checking the result in a browser.

Source