Tag

styled-components

0 views collected around this technical thread.

Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Jun 19, 2023 · Frontend Development

Understanding CSS, UI, and Style Systems: Tailwind, Styled-Components, and Behavior Libraries

This article explores how modern frontend development separates UI into CSS extensions, behavior libraries, and style systems, compares Tailwind with Bootstrap, discusses the advantages of styled‑components and behavior‑only libraries like Radix‑UI, and offers guidance on building a custom component library with a personal style system.

Behavior LibrariesUIcss
0 likes · 11 min read
Understanding CSS, UI, and Style Systems: Tailwind, Styled-Components, and Behavior Libraries
DaTaobao Tech
DaTaobao Tech
Sep 29, 2022 · Frontend Development

Understanding the Implementation of CSS-in-JS with Styled-Components

The article explains CSS‑in‑JS fundamentals, examines styled‑components’ source code—including its styled function, createStyledComponent factory, and runtime style injection—compares it with emotion, demonstrates a simple SolidJS MVP implementation, and discusses the technique’s rise, limitations, and possible compile‑time or atomic‑CSS future.

CSS-in-JSImplementationReact
0 likes · 11 min read
Understanding the Implementation of CSS-in-JS with Styled-Components
ByteDance Dali Intelligent Technology Team
ByteDance Dali Intelligent Technology Team
Jul 28, 2021 · Frontend Development

Advanced Techniques and Best Practices for Using styled-components in React

This article shares practical tips, patterns, and mental models for mastering styled-components in React, covering CSS variables, context styling, component encapsulation, inheritance, margin handling, z-index management, the "as" prop, priority tricks, and related tooling to write cleaner, more maintainable UI code.

CSS variablesCSS-in-JSPerformance
0 likes · 19 min read
Advanced Techniques and Best Practices for Using styled-components in React
ByteDance ADFE Team
ByteDance ADFE Team
May 13, 2021 · Frontend Development

CSS‑in‑JS in React: Problems with Traditional CSS, Various Styling Approaches and Comparison of Popular Solutions

The article explains why traditional global CSS is problematic for component‑based development, reviews several ways to write styles in React—including BEM‑constrained classNames, inline styling, CSS Modules and css‑loader—then introduces CSS‑in‑JS concepts, demonstrates the Emotion library, compares popular packages and offers practical recommendations for choosing a styling solution.

CSS ModulesCSS-in-JSemotion
0 likes · 15 min read
CSS‑in‑JS in React: Problems with Traditional CSS, Various Styling Approaches and Comparison of Popular Solutions