design-systems-that-ship.md
Design Systems That Actually Ship
Lessons from building NPUI tokens, primitives, and the gap between Figma and production.
- Design Systems
- React
- NPUI
Most design systems die in Storybook. The ones that survive share a pattern: they optimize for shipping speed, not documentation completeness.
Start with tokens, not components
Before Button v47, define:
- Color roles (
accent,muted,destructive) not hex values scattered in JSX - Spacing scale tied to Tailwind or CSS variables
- Typography pairs (sans for UI, mono for code labels)
- Motion presets (spring configs you reuse everywhere)
NPUI started here. Components came second, and each one had to earn its place in the bundle.
Primitives over patterns
A Card with three variants beats twelve one-off card layouts in product repos. But a Card that wraps every possible layout becomes impossible to maintain.
The balance:
| Layer | Purpose | Example |
|---|---|---|
| Tokens | Visual language | --accent, --radius |
| Primitives | Composable building blocks | Button, Badge, Input |
| Patterns | Product-specific | Checkout form, dashboard shell |
Patterns live in apps. Primitives live in the library.
Match the design tool to the runtime
Figma auto-layout โ CSS flexbox mental model. The fastest teams treat the design system as the contract and accept that implementation details differ.
What matters is:
- Same spacing rhythm in design and code
- Same interaction states (hover, focus, disabled)
- Same naming so designers and devs share vocabulary
Ship the docs you will read
Developers don't read 200-page PDFs. They read:
- One-line install instructions
- Copy-paste examples
- Props tables generated from TypeScript
If your docs aren't the first tab you open when using your own library, rewrite them.
Closing thought
A design system is a product. Its users are your future self and your teammates. Ship small, iterate in production, and delete what nobody imports.
Related
Continue reading
More notes on similar topics.
How React 18 schedules updates, keeps the UI responsive during heavy renders, and what useTransition actually buys you.
- React
- Performance
The horse is doing the running. You're still the one who has to stay balanced, read the terrain, and not fall off. That's the whole difference between vibe coding and actually directing the thing.
- AI Engineering
- Vibe Coding
The Day the Facility Guy Shipped a Feature to My App
July 29, 2026
I taught our building's maintenance guy how to vibe code for fun. Twenty minutes later he'd chatted his way into a working feature inside one of my real apps. Here's what actually happened, and why it didn't disprove anything I've written in this series.
- AI Engineering
- Vibe Coding