CONTACT US

React TL;DR – a human filter for most useful tech content.

All posts

How To Use Styled-Components In React

Why Styled Components?

 

Apart from helping you to scope styles, styled components include the following features:

 

  • Automatic vendor prefixing
    You can use standard CSS properties, and styled components will add vendor prefixes should they be needed.
  • Unique class names
    Styled components are independent of each other, and you do not have to worry about their names because the library handles that for you.
  • Elimination of dead styles
    Styled components remove unused styles, even if they’re declared in your code.
  • and many more.