paint-brush
​​Choosing Between SASS vs CSS Modules vs CSS-In-JSby@ndimares
468 reads
468 reads

​​Choosing Between SASS vs CSS Modules vs CSS-In-JS

by Nolan SullivanJuly 16th, 2022
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

We chose to move forward with CSS-in-JS as our primary styling mechanism in order for the UIs we build to be easily embeddable within external UIs. We’d love to know your thoughts and how you reached decisions about styling your UI.
featured image - ​​Choosing Between SASS vs CSS Modules vs CSS-In-JS
Nolan Sullivan HackerNoon profile picture


We are in the midst of building the first version of our API Ops platform. One of the components which we are actively building is a developer console where devs can get an overview of their APIs and each endpoint’s performance. While building our UI, we are debating many of the fundamental front end architecture decisions that will shape our UI development. One of the biggest debates thus far was whether we would use SASS or CSS-In-JS for our styling.


We know developers are facing these same questions every day, so we want to publish our thoughts in case they are useful to anyone else. Ultimately, we chose to move forward with CSS-In-JS as our primary styling mechanism for reasons specific to our business; we considered it important for the UIs we build to be easily embeddable within external UIs. We felt that CSS-In-JS was the best option for embeds, because integrators wouldn’t need to worry about dealing with style injection, and could theme our components into their style.


We’d love to know your thoughts and how you reached decisions about styling your UI? Have you had any bad experiences with CSS-In-JS?


Below is our full internal conversation only minimally edited for brevity:

What is SASS

Reduce, reuse, recycle

It's all CSS in the end

Another angle

The closing thoughts