Designing React Interfaces: A Journey Through Modern Styling Techniques
summary
Builds a Chakra/NextUI‑style Button API with live demos using vanilla CSS vars, styled‑components/CSS‑in‑JS, style‑system, class‑variance‑authority, Tailwind (+ tailwind‑variants) and Panda CSS, showing a full Chakra clone implemented in 2021. Compares theme-driven token flows, variant-based API patterns, and tradeoffs: CSS‑in‑JS offers dynamic props but incurs runtime overhead and server rendering costs; style‑system supplies responsive props; Tailwind generates semantic classes and creates eight theme + dark combinations in four files; Panda provides build-time generation with no runtime cost.
AI-written summary · about
chapters (29)
- 0:00Introduction to talk
- 0:43Goals of modern styling
- 2:07Agenda and best practices
- 3:09CSS variables and class names
- 5:38Pros and cons of CSS approach
- 6:05Style components overview
- 7:53Dynamic styling with CSS-in-JS
- 8:57Component composition
- 10:23Pros and cons of style components
- 10:45Introduction to style systems
- 11:50Building a design system
- 13:15Utility functions and type safety
- 14:21Button component with style system
- 16:03Pros and cons of style systems
- 17:06CSS-in-JS performance concerns
- 17:29Class variance authority
- 19:17Flexible theme-driven utility classes
- 21:47Pros and cons of CVA approach
- 22:30When to use CSS and CVA
- 22:52Tailwind CSS overview
- 24:16Creating buttons with Tailwind
- 25:42Compound variants and themes
- 26:26Pros and cons of Tailwind
- 27:55Multiple themes with Tailwind
- 28:25Panda CSS introduction
- 29:07Design tokens in Panda CSS
- 30:10Custom utilities and responsiveness
- 30:55Pros and cons of Panda CSS
- 31:39Key takeaways and conclusion
related talks
27mStyles & SASSy: Choosing the Right React Styling Solution
07mReact Components and How To Style Them
29mStyling React For Reuse
30mDynamic Styling Systems with React
22mStyling Components for React UI Kits
25mStyled and SASSy: Choosing the Right React Styling Solution
32mThe Modern Way of Making Websites in React
44mWriting good components
