Back to News

Building a UI Library in Rust: The Slaps Were Worth It

2026-04-15RustDioxuseq_uiAccessibilityTailwind CSSPlayground Architecture ↗

The Compiler Doesn't Care About Your Feelings

EqButton component in the eq_ui playground showing all five variants and three sizes with Gruvbox theme

Building eq_ui has been one of those journeys where you start thinking "how hard can a button component be?" and three months later you're deep in WAI-ARIA tree view specifications, arguing with the Borrow Checker about who actually owns a HashSet, and questioning every life decision that led you to this moment.

Rust doesn't care about your feelings. It will reject your code at 2am because you tried to borrow something mutably while a read reference was still alive somewhere three closures deep. And honestly? That's the best thing about it. Every compiler error is a tiny slap that says "you didn't think this through, try again."

Coming from a JavaScript background where everything compiles and nothing works, there's something deeply refreshing about a language where if it compiles, it probably does what you meant. The learning curve is real, it's steep, and some days it feels like climbing a wall covered in lifetime annotations. But every time you reach a new ledge, the view is incredible.

Constraints That Made It Better

EqGrid organism in the eq_ui playground showing data table with pagination and SolarizedDark theme

What surprised me most was how much the constraints of Rust pushed me toward better design. When the compiler forces you to think about ownership and data flow upfront, you end up with components that are genuinely well-structured, not because you're disciplined, but because the language won't let you be lazy.

eq_ui now has 29 components with full ARIA accessibility support, 23 built-in themes, and a Storybook-style playground built without a single line of JavaScript, all in pure Rust with Tailwind CSS. The grid organism alone handles sorting, filtering, pagination, virtualization, drag-and-drop, row reordering, and bulk actions with full WAI-ARIA table semantics.

One of the most satisfying parts was designing the playground itself. It started as a monolithic 3,500-line example file. Over time it evolved into a self-describing system where each component carries its own metadata: name, category, style tokens, usage examples, interactive demo, and variant gallery. A ComponentDescriptor pattern behind a feature flag, so it costs zero binary size for library consumers. External users can register their own components alongside eq_ui's built-in set and they appear in the same tree with identical prop controls. That architecture made everything cleaner and made the library genuinely extensible.

Try It. You Will Suffer. It's Worth It.

EqAccordion molecule in the eq_ui playground showing mode comparison and code examples with Gruvbox theme

The Dioxus community has been incredible throughout this process, always willing to help when I hit a wall, which was often. If you're a frontend developer curious about Rust, my honest advice is: try it. You will suffer. The compiler will humble you. You will Google "cannot borrow as mutable because it is also borrowed as immutable" more times than you'd like to admit.

But somewhere between the fifth rebuild and the tenth cargo check, you'll realize you're building something solid. Something that works. Something that won't mysteriously break at runtime because someone passed undefined where a string should be. And that feeling? Totally worth the slaps.

Building the future, one line at a time.

© 2026 Equidevium. All rights reserved.