▲ | imiric 4 days ago | ||||||||||||||||||||||
... And end up with elements that have dozens of classes until you need to parse CSS in your head in order to figure out what the element is supposed to look like. This methodology completely misses the point of using classes to begin with. Good class and ID names should be semantic, just like the markup. Don't describe what the CSS does; describe what the element is. Not only that, but it introduces useless abstractions that could've been avoided by just writing CSS directly. How is `.content-center` better than `align-content: center`? Tailwind and its ilk are one of the worst trends to have ever happened in web development. It's making people forget how to use CSS, while being useless in the process. I truly don't understand it. And, yes, I've worked on projects that used it extensively. It's awful. | |||||||||||||||||||||||
▲ | ChocolateGod 4 days ago | parent | next [-] | ||||||||||||||||||||||
> I truly don't understand it Quick iteration and good relative spacing for margins, paddings, dimensions etc. A lot of people combine Tailwind with something like Vite so they're getting instant previews and don't need to swap focus to a style sheet to style their component. I swapped to Tailwind and honestly could never swap back. | |||||||||||||||||||||||
▲ | 4 days ago | parent | prev | next [-] | ||||||||||||||||||||||
[deleted] | |||||||||||||||||||||||
▲ | sieabahlpark 4 days ago | parent | prev | next [-] | ||||||||||||||||||||||
[dead] | |||||||||||||||||||||||
▲ | vehemenz 4 days ago | parent | prev [-] | ||||||||||||||||||||||
I appreciate strong opinions, but I appreciate good arguments even more. And there's just nothing here. You're raising a bunch of meyerweb talking points from 2003, except why? WHY does markup need to be "semantic" in the sense that you mean? Actually, WHY? Provide a supporting argument that it makes a difference to developers or end users. Remember, we've all been doing it that way for years, and we switched to Tailwind. You need to have something more compelling to developers who have already made up their minds. > Not only that, but it introduces useless abstractions that could've been avoided by just writing CSS directly. How is `.content-center` better than `align-content: center`? There are several reasons, but media queries would be reason 1. Why is it useless, again? Remember, we can't tell what your high-level abstractions do without opening at least two files, plus we have to understand any inherited/cascading rules on top of that. If that complexity doesn't matter, then it's argument time again. > It's making people forget how to use CSS Tailwind relies on CSS for its class names. How would one use it without knowing CSS in the first place? Secondly, why would it be bad (argument time again)? The reasons for Tailwind are well understood. It's way faster, trivial to pick up, and easier to maintain longterm, especially in a team environment, than bespoke CSS/DOM abstractions that have layers of hidden complexity. Now, what does your way of doing CSS offer? Remember, tons of people switched from older methodologies to Tailwind and have already priced in the benefits, small as they were. | |||||||||||||||||||||||
|