Used by folks at
To create beautiful websites like these
To download styled-components run:
That's all you need to do, you are now ready to use it in your app! (yep, no build step needed 👌)
It's recommended (but not required) to also use the styled-components Babel plugin if you can. It offers many benefits like more legible class names, server-side rendering compatibility, smaller bundles, and more.
Let's say you want to create a simple and reusable <Button /> component that you can use throughout your application. There should be a normal version and a big and primary version for the important buttons. This is what it should look like when rendered: (this is a live example, click on them!)
First, let's import styled-components and create a styled.button: