DEV Community

Cover image for Why I Chose Tailwind CSS as a Frontend Developer — And Never Looked Back

Why I Chose Tailwind CSS as a Frontend Developer — And Never Looked Back

JSXJunkie on July 16, 2025

👋 Introduction When I first started learning frontend development, styling a webpage felt overwhelming. Writing long CSS files, naming classes, man...
Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

I always read these tailwind articles hoping that one day one will answer the one question that actually matters: We know inline styles are bad; why should we go back to using them?

I'm sure most of us know about the short-term strengths of TW over separate CSS; but we also know that style="" has all the same strengths or more. And there are good reasons we aren't using that anymore.

Collapse
 
harsh_p30 profile image
JSXJunkie

Yeah, I see what you mean. But inline styles are just more work. Tailwind is like inline styles done right—faster, cleaner, and easier for the whole team. Unless we miss the table-layout era, I’d stick with TW. 😅

Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

Inline styles aren't bad because they require more typing; they're bad for very deep structural problems that I haven't seen TW address in any way.

Table layouts are also an interesting thing to bring up; because tailwind seems to mirror all the fundamental problems with tables.

Makes me wonder if 10 years from now, people will look back on tailwind as another one of those cringe ways we used to build websites, while doing the next iteration of the exact same thing rather than just use CSS.

Thread Thread
 
harsh_p30 profile image
JSXJunkie • Edited

yeh, every developer has their own perspective and preferences.

My take is this: inline styles are like duct tape on a web app, while Tailwind is like LEGO bricks. It's not replacing CSS, but offering a faster and more consistent way to use it.

In 10 years, we may laugh at today's trends, but I doubt we'll laugh at clean, maintainable design systems. Just like React builds on top of plain HTML to make development easier (see my blog on this), Tailwind is simply a smarter way to use CSS.

Thread Thread
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

Sure, but all you've said is that tailwind somehow gets around all the inherent problems with inline styling, but not how it does it. Every time I've looked at TW it seemed to just have all the same problems with a different syntax.

Thread Thread
 
harsh_p30 profile image
JSXJunkie

Sure Tailwind is built on top of CSS, so it inherits both its strengths and weaknesses.

The difference is that Tailwind knows how to manage those problems. Inline styles sit directly in the HTML and can’t handle things like pseudo-classes (:hover), media queries, or consistent design tokens.
Tailwind, however, uses predefined utility classes tied to a centralized design system (spacing, colors, typography). So while it might look like inline styles at first glance,
under the hood it’s structured, reusable, and far more maintainable.”

Thread Thread
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

I think you're somewhat misunderstanding the problem with inline CSS.

There are many features nowadays that can't really be used with inline styles; but the knowledge that inlining styling inside the markup predates many of these features.

Again, the problem is with inlining styles, not with the specific limitations of using style; the problems result from inlining styles directly in the markup rather than separate CSS files. Tailwind, to my knowledge, doesn't really address these problems in any way whatsoever. That's what I'm asking about.

Thread Thread
 
harsh_p30 profile image
JSXJunkie

Exactly—that's the whole point. The real issue lies in inline styles directly in the markup, not in external CSS. And that’s where Tailwind is fundamentally different.

I think there's just a bit of misunderstanding here, Otherwise, your understanding of the issue is solid.

Thread Thread
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

How is Tailwind different though? You're still inlining all of your styles directly in the markup, just with the extra indirection of a DSL.

Thread Thread
 
harsh_p30 profile image
JSXJunkie

It may look like inlining, but Tailwind isn’t injecting actual style rules into the markup like inline CSS does. Instead, it applies predefined utility classes that reference centralized, reusable CSS scoped, optimized, and purged at build time.

its not just about extra indirection of DSL, it’s about maintainability, consistency, and scalability.

Thread Thread
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

Yes, as I said, it replaces inline CSS with a custom DSL; but it is still, fundamentally, inlining styles, just like CSS though. All the other adjectives are kind of just noise:

  • "centralized" just like the meaning of CSS is centralised in the browser
  • "reusable" just like CSS properties
  • "optimized" not nearly as optimized as inline CSS, as it still has an additional layer of indirection
  • "purged at build time" whereas with inline CSS there isn't even anything to purge

its not just about extra indirection of DSL, it’s about maintainability, consistency, and scalability.

I agree, and again, tailwind is still inline CSS just like style, and I'm still looking for why on earth it would be any more maintainable or why the fundamental problems with inline styling wouldn't apply to it.

Thread Thread
 
harsh_p30 profile image
JSXJunkie

If you think Tailwind is just inline CSS with a fancy alias, you’re missing the entire point of utility-first design systems.
Inline styles are one-offs—hard to maintain, impossible to scale. Tailwind builds from a consistent, shared system. That’s not ‘just styling in markup’—that’s structured CSS applied efficiently. Big difference.

Thread Thread
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

you’re missing the entire point of utility-first design systems.

Well, yea, if you scroll up, basically my entire point is that I'm wondering if I'm missing something but nobody has really explained it yet.

Inline styles are one-offs—hard to maintain, impossible to scale. Tailwind builds from a consistent, shared system.

But Tailwind is inline styling though. And yea, that should make it hard to maintain and impossible to scale. Yet tailwind users seem very convinced that it doesn't. I'd love to know how that is, because it doesn't seem to make sense.

Tailwind builds from a consistent, shared system.

Yes, but inline CSS is exactly the same. It builds from a consistent, shared system, aka. CSS, which is implemented by browsers directly, rather than Tailwind, which is just a different system implemented on top of CSS.

That’s not ‘just styling in markup’—that’s structured CSS applied efficiently. Big difference.

What's structured about it? If you want to make the text in a paragraph bold, you go to that tag and set it to bold; whether you do so by some tailwind class or css attribute, you're still inlining the style "bold" in your markup.

Neither approach is more or less structured than the other, they're just different DSLs for the same job. But, correct me if I'm wrong, tailwind still isn't any more declarative or reusable than inline css in any meaningful way.