Skip to content
Tech News
← Back to articles

Moving away from Tailwind, and learning to structure my CSS

read original get CSS Flexbox and Grid Guides → more articles
Why This Matters

This article highlights a developer's transition from using Tailwind CSS to adopting a more structured, semantic HTML and vanilla CSS approach. It underscores the importance of understanding CSS architecture and how leveraging familiar systems can improve maintainability and clarity in web development. The shift also reflects broader industry trends towards more customizable and understandable styling methods, benefiting both developers and end-users.

Key Takeaways

Hello! 8 years ago, I wrote excitedly about discovering Tailwind.

At that time I really had no idea how to structure my CSS code and given the choice between a pile of complete chaos and Tailwind, I was really happy to choose Tailwind. It helped me make a lot of tiny sites!

I spent the last week or so migrating a couple of sites away from Tailwind and towards more semantic HTML + vanilla CSS, and it was SO fun and SO interesting, so here are some things I learned!

As usual I’m not a full-time frontend developer and so all of my CSS learning has happened in fits and starts over many years.

When I started thinking about structuring CSS, I was intimidated at first: I’m not very good at structuring my CSS! But then I started reading blog posts talking about how to structure CSS (like A whole cascade of layers or How I write CSS in 2024) and I realized a couple of things:

Every CSS code base has a bunch of different things going on (layouts! fonts! colours! common components!) It’s extremely useful to have systems or guidelines to manage each of those things, otherwise things descend into chaos Tailwind has systems for some of these, and I already know those systems! Maybe I can imitate the systems I like!

For example, Tailwind has:

a reset stylesheet

a colour palette

a font scale

... continue reading