4 ms·
I'm not sure I fully agree with your view on what tailwind is and why it is growing. In my opinion, tailwind is gaining some popularity because some people fin
by jonwinstanley 3y ago
I'm not sure I fully agree with your view on what tailwind is and why it is growing.
In my opinion, tailwind is gaining some popularity because some people find it faster and easier to use than writing traditional CSS files.
I realise it also has some downsides, and seeing all those class names in the html is particularly ugly, but if the people using it got their project out faster, then surely there is a place for it?
- 3cats-in-a-coat 3y agoTechnology choices, and life's choices in general are like a spectrogram of different wavelengths with positive and negative values... Like "this will help you today, but bite you in the rear tomorrow", or "this will help you tomorrow, but be annoying today". And it also varies by different conditional developments, if this happens, if that happens, can you implement a change, or the solution is "write-only" and so on. One of the tests of intelligence is can you defer immediate gratification, so you can reap higher rewards in time that compound themselves, or you lack impulse control and therefore you essentially have the model behavior of a house fly. This incessant focus on "here, now, me" that I see glorified, which doesn't consider at all anything outside a point in time and space that demands the impulse to be immediately satisfied... is not a good direction for tech, or for society at all. It's like choosing porn over a family. Obviously, I'm describing a broader problem here, not just some CSS tool, but Tailwind and many of the "frameworks" we see pushed in the industry do also embody this philosophy, quite clearly. Many things do these days. Ship faster, do less, faster, faster, faster. To what end? Are your projects so worthless, that you need to ship them today and then leave hell to yourself and others few months down the line? Not to mention that all the claims Tailwind is "faster", somehow, are written in weasel language to hide the fact Tailwind adds tangible, often significant lag and load to people's devices when they use your site. Does this matter? Of course, a fancy experiment is all good. You won't see me writing long posts about how Brainfuck is the end of humanity. But Tailwind has a good size community that actually believes their approach is superior, they're on a mission from God, and it's become viral, dragging in more and more people in, and influencing other projects into the same stupidity. What else does it mean to write a post called "Why Tailwind won". Won what? Was there a war going on? Won over what? Bootstrap? Bootstrap is a framework. Won over CSS? It runs on CSS, it's not an "alternative to" CSS, although it sure makes it impossible to use most of the benefits of CSS in a sane way. Yay, what a win. If Brainfuck was totally serious, and you saw your company is starting to write critical projects in Brainfuck, wouldn't that give you a serious pause?
- jonwinstanley 3y agoWhat makes you think tailwind would be hell in the future though? It's just a load of classes on html elements. Maintenance is pretty easy. I do agree with you on the headline though, of course tailwind hasn't won anything!
- 3cats-in-a-coat 3y agoFirst, the site uses some weasel language to speak about how much they're "focused on performance" in such a way as you think Tailwind is literally faster than doing normal CSS. It's not. It's a heavy approach and while you can always find edge cases to the contrary, in general it leads to pages that add lag and load to people's devices. If you have a very simple page this doesn't matter, but as your site/business grows, it does. Second, Tailwind obviously promotes a ton of repetition in the same way that using presentational attributes from the 90s and style="" does. This not only adds, again, burden to the CSS engine and DOM, but this "ease of copy pasting" that the author boasts about in the linked blog means you can easily end up with tons of subtle or not so subtle inconsistencies in your site's code and components, UI. Copy pasting is easy. But there's a reason why we define classes, functions, modules, and reuse them, instead of copy-pasting our code everywhere. Copy pasting is a strategy for a quick start and a very short journey as you paste more and more variations of what you're trying to do around your site. Now change them all consistently. Oh shit, I guess... find/replace + regex? This works sometimes, but it's a deeply unserious approach to change management in an application/site at scale, and means your velocity and quality both will suffer. I'm aware of the way to define custom classes as sort of "components" in Tailwind, but at this point... you're literally using Tailwind as you would CSS, but with a ton of indirection, gibberish, and very very unclear precedence/specificity rules. You will also get many people complaining about compilation speed for larger sites. A problem that is quite bizarre to have for styling with a language that doesn't require compilation when you use it in a sane way (and SASS etc. are extremely fast and don't have this problem, there's even a Rust SASS parser I believe, that's even faster). Tailwind also severely restricts your precision and expression. I probably don't have to explain the limitations of inline styles when those styles have to change from user interaction, or for different devices, and container size and so on. Tailwind makes all this extremely bizarre, if it addresses it at all. In "plain" CSS (and other more reasonable tools like SASS), it's trivial.