Hacker News new | ask | show | jobs
by ellinoora 878 days ago
My biggest issue with Tailwind is point #5 on the article: Tailwind encourages div/span-tag soup. Together with the class name soup my HTML becomes unreadable.
3 comments

A big issue that these articles never mention is that using browser dev tools to debug CSS becomes a huge pain with tailwind. It also makes it harder for community to create custom themes/user scripts for your website/app since targeting specific elements becomes incredibly hard when no class names exist.
This so much.

Not to mention, it basically puts a dsl on top of CSS.

CSS by itself is great, and with all the modern changes you hardly need to use preprocessors like SCSS (there's still some advantages but far fewer than say, 5 years ago).

I don't understand the people in the thread that hate writing CSS...

> HTML becomes unreadable

To be honest, I don't find that a problem. Most frontend development is done in a higher-order abstraction like React. For the most part, I don't read HTML and I don't write HTML. If you use the right level of composition, "div soup" should never really be a problem.

Not great for accessibility, not great for performance.
> I don't read HTML

For a reason

How does Tailwind encourage div/span tag soup compared to anything else? You literally cannot do anything on the web without a div/tag soup
It doesn't the author is just bad at semantic HTML. That first example should be an `<article>` and the 5th example doesn't actually show div/span soup.