Guides

Task-oriented pages. Concepts live under Concepts.

  • Distillate vs CSS-in-JS — when Distillate is the right tool
  • Declare and select variations — named diffs, { flatten }, { alternates }
  • Read values outside CSS — literal theme values for SVG and other non-CSS surfaces
  • Ship a compact artifact — tree-shaken CSS for HTML that leaves the app
  • Integrate with a React renderer — collect handles while rendering
  • Migrate from Emotion — createEmotion over the same registry
  • Test the var invariant — every var(...) has a declaration
  • Avoid readable-name collisions — hyphen-joined names must be unique
Previous
Single-copy invariant
Next
Distillate vs CSS-in-JS
  • View as Markdown
  • Edit this page
  • Distillate

  • Getting started
    • Installation
    • Quick start
    • Your first stylesheet
  • Concepts
    • The distillery
    • Tokens and vars
    • Authoring
    • Reachability collection
    • Naming and output
    • Ordering and specificity
    • Single-copy invariant
  • Guides
    • Distillate vs CSS-in-JS
    • Declare and select variations
    • Read values outside CSS
    • Ship a compact artifact
    • Integrate with a React renderer
    • Migrate from Emotion
    • Test the var invariant
    • Avoid readable-name collisions
  • Reference
    • Entry points
    • Environment
    • Generated API
    • @elastic/distillate
      • emotion
      • index
      • testing
    • OKF map
Elastic logo

© 2026 Elasticsearch B.V. All Rights Reserved.

  • Terms of Use
  • Privacy