fac19 / work-in-progress

Weeks 11-13 Student Project
https://wip-app.netlify.app/
3 stars 0 forks source link

Styling 💅 *Styled Components VS CSS* #145

Closed jamesj-0 closed 4 years ago

jamesj-0 commented 4 years ago

I love the clean styling and the illustration is badass!

I noticed in your code base you have empty css files, maybe a quick spring clean if you get the chance 😁

I have some questions about why you went with styled components and not straight up CSS, did you find any limitations and what was your justification for your choice?

^ I know sometimes these decisions are made based on what we want to learn at this point, but Its good to consider as these are common interview questions

jackherizsmith commented 4 years ago

Personally I much prefer styled components since the CSS is more clearly related to each element - it's almost an advantage over regular styling outside of React, since you have to put energy into ordering your CSS file so that it can be related to your HTML.

The only downside could be losing understandable class names (i.e. BEM) - except that that is really just a requirement of the problem that styled components also solve (knowing which CSS refers to which HTML element)