WorkshopBuild log
Building 64 UI Components in Rust Without a Framework
How maud-ui delivers shadcn-quality components with zero JavaScript framework, 22 KB gzipped, using maud templating and htmx.
I shipped maud-ui1 this week: 64 accessible, headless UI components for Rust web applications. No React, no virtual DOM, no build step for consumers. Just pure Rust functions that return HTML.
The bet was simple: maud for templating, htmx for interactivity, and shadcn/ui as the visual reference. The result is 22 KB gzipped (JS + CSS combined) and works with any Rust web framework.
Why Rust for UI components?
The Rust web ecosystem has excellent server frameworks (Axum, Actix) but the component story is thin. If you want styled, interactive UI, your options are: write raw HTML strings, use a heavyweight WASM framework like Leptos, or reach for JavaScript.
maud-ui fills the gap. Components are pure functions: Props -> Markup. No state management, no lifecycle hooks, no hydration. The server renders HTML, htmx handles interactivity, and CSS custom properties handle theming.
The three tiers
The 64 components are organized into three capability tiers:
- Static (pure HTML/CSS): buttons, badges, cards, typography
- Interactive (HTML/CSS + htmx attributes): accordions, tabs, dialogs, command palette
- Rich (HTML/CSS + htmx + a small JS widget): code editor (Monaco), charts, data grids
Each tier adds a dependency layer but the consumer only pays for what they use.
What I learned
Building a component library in a systems language forces different design decisions. No useState, no useEffect, no reactivity model. Every interaction is an HTTP round-trip or a CSS transition. This constraint is liberating: the components are fast, accessible by default, and trivially cacheable.
The live demo is at maudui.herman.engineer2.
Written by Herman Geldenhuys in Montreal.
Sources
- GitHub, maud-ui
- maudui.herman.engineer, maudui.herman.engineer
Keep reading
Rent the Frontier, Own the Workhorse
The strangest chart in AI shows usage flooding toward cheap open models while the money concentrates at the frontier. It is not a paradox: intelligence is two purchases wearing one name, and only one of them compounds.
The Four-Minute Mile
In one October week, AI mathematics left one camp furious and another throwing a party. The best news came from neither: within hours of a machine nudging an old limit, people were building on it, some with machines of their own.
Depth Is a Disagreement
When an AI recommendation came with a generated justification, evaluators followed it more readily. Bessel’s 1838 star measurement offers the way out: a second view, taken from somewhere else. For AI work that means a second model from a different family, and keeping the two views far enough apart to disagree.