DEV Community

Cover image for Styled components shoud be in separated .js file?
Jean Santana
Jean Santana

Posted on

Styled components shoud be in separated .js file?

When we use CSS, we have a separated file and import inside of.jsx component, but with Styled Components what is the best practice? Inside of component or outside?

Top comments (1)

Collapse
 
mattc profile image
Matthew Claffey

emotion.sh/docs/introduction is quite nice, allows you to separate CSS from js quite well. It's like styled components but looks more flexible.