Live data from Hacker News

Why Tailwind CSS Won

matt-rickard.com

281–290 of 559 posts

Re: Why Tailwind CSS Won

#281
post #234

Earlier quoted context omitted.

+1. Let's say things how they are: Tailwind is a small catastrophe from an implementation, performance and maintenance point of views. It got few things quite well in being a more modern bootstrap, had a stellar marketing and it's color palettes are really well done and leagues above the default material ones. ...that being said... Tailwind's biggest pro is that it allows people that _don't_ know css that much to sty…

One of the things that tailwind achieves is let you ship style in a way that is encapsulated within components and works reliably across any framework (including server-side rendering frameworks, react, svelte etc).

That's not unique to tailwind.

Re: Why Tailwind CSS Won

#282

Earlier quoted context omitted.

> why would it be? Because most frontend engineers cannot make something as visually appealing as Tailwind’s defaults and most designers cannot make frontend abstractions as ergonomic as Tailwind’s. Now it seems like you’re suggesting just reimplementing Tailwind? Or yes you can have one of your FE engineers and one designer try to dream up your own Tailwind but again: why? Now you’re consuming two people for somethi…

If the Tailind defaults are used in a design language file, wouldn't it be simpler? If it's only a problem of "aesthetics", 20 minutes is enough to use Tailwind's defaults in pure CSS. No need for calling a designer here either. Side benefits include that there is then no need to update any dependencies or library, no need to run a JIT server, no need for a new syntax, no need to wait for implementation of new CSS fe…

Just checking that I understand your suggestion: it’s that you copy/paste Tailwind into a file called “designsystem.css” and then say that you are not using Tailwind?

Or are you saying take their design system and use your own syntax for it (so it’s less complete than TW, less well-documented, and less transferable to/from the vast resources of the internet centered around TW)?

Re: Why Tailwind CSS Won

#283

I find Tailwind's claim that you can "build modern websites without ever leaving your HTML" to not be entirely correct. Instead of context switching from my `.html` to a `.scss` file, I just end up context switching to their documentation website to find the syntax they used. It's internally inconsistent, so you can't guess what the Tailwind class name is for styling, while you can do this for CSS on the majority of…

To enjoy tailwind you have to install the vscode plugin so it will speed things up when searching for the right class. Also watch some short tutorial to get an overview. If you don't appreciate it after this then it really isn't for you

Re: Why Tailwind CSS Won

#284

Earlier quoted context omitted.

+1. Let's say things how they are: Tailwind is a small catastrophe from an implementation, performance and maintenance point of views. It got few things quite well in being a more modern bootstrap, had a stellar marketing and it's color palettes are really well done and leagues above the default material ones. ...that being said... Tailwind's biggest pro is that it allows people that _don't_ know css that much to sty…

I think Tailwind could be made good for usage at enterprise scale, for example, as a customisable foundation for a branded design system. If for example Figma offered first-class support for Tailwind-like utility classes in the form of a modernised "styles" or "composite tokens" feature, then mapping from a design system to Tailwind-based code could be pretty simple. But right now, it's anything but. In my experience…

How's any of that unique to Tailwind?

Re: Why Tailwind CSS Won

#285
post #249

Earlier quoted context omitted.

My experience mirrors yours 100%. What the parent comments seem to be describing are Tailwind in a context where people don’t know CSS that well. Yes, that will be a catastrophe. But so will SASS or vanilla CSS — even more so. Tailwind is a utility, not a replacement for fundamental knowledge.

On the other hand, people that know CSS very well will not need suddenly tailwind to get some utility classes.

And people that know (Python|Ruby|PHP|Go|Etc) don't need the framework to implement a web app, yet we use them anyway.

What is the value of reimplementing a bunch of this if it already exists? What's the value of having every developer learn some poorly-documented in-house system when we can use one that's already out there with full documentation, examples, references on StackOverflow, etc?

Re: Why Tailwind CSS Won

#286

Earlier quoted context omitted.

None of this mirrors my experience whatsoever. That’s “how things are” for me. I know CSS very well and Tailwind is probably the largest productivity boost I’ve encountered since, I don’t know, learning vim? It’s way faster than SASS/SCSS which is itself way faster than raw CSS. It also yields far more self-contained and more readily composable components than any other styling mechanism. Your comment doesn’t resonat…

Agreed. I've been using CSS for over two decades now. The composibility, reusability, and maintainability benefits of CSS have just never materialized outside of some very tight scopes such as toy projects or single developer projects as far as I've seen. And we pay heavy costs having half of the context of whatever we're working on living in an entirely separate file (any generally multiple discrete areas within tha…

This resonates quite well with my experience.

If you understand CSS well and you’re using TW, you will ~never have to go chase down some crazy style cascade via the inspector.

No amount of understanding CSS can save you from that in a complex CSS/SCSS codebase, because it’s how CSS is meant to be used.

Re: Why Tailwind CSS Won

#287
post #163

I love tailwind, and I've been writing CSS professionally since CSS2.1. I have often debated with many developer friends why it has performed so well, and this article really missed some big reasons: 1. It's works extremely well with the current component-focused UI frameworks (react, svelte, etc). Subsequently, the verboseness that is often a complaint isn't an issue at all, but a feature. 2. Does everything out of…

1. For component usage and in this case only restricted. You can only style the top layer of a component, not each part. But for component development, tailwind made it complex, e.g. if you want to make it possible to set / add custom styles to each sub-element. 2. Vanilla CSS too. 3. For designers with individual styling of components Tailwind is great, but not for app where elements have the same style or developed…

You can use normal CSS and use @apply if that was necessary.

Re: Why Tailwind CSS Won

#288
It takes some time to get used to it (basically, memorizing most import class name schemes). But this is the first time I can open an old project I haven't seen for a year and directly start changing the styles of stuff without the fear of breaking anything or having to read into how the CSS is managed again.

I also like that it lets you build anything and does not have a default look.

Re: Why Tailwind CSS Won

#289
post #249

Earlier quoted context omitted.

My experience mirrors yours 100%. What the parent comments seem to be describing are Tailwind in a context where people don’t know CSS that well. Yes, that will be a catastrophe. But so will SASS or vanilla CSS — even more so. Tailwind is a utility, not a replacement for fundamental knowledge.

On the other hand, people that know CSS very well will not need suddenly tailwind to get some utility classes.

There are tons of people who are perfectly proficient in CSS who are not won over to utility classes. As you become more won over, you start writing files full of utility classes that… wait for it… someone else has already written! With huge coverage over CSS! And really good defaults! And lots of escape hatches!

And to top it off, nothing guarantees your colleagues are actually going to use those instead of creating their own ad hoc “semantic CSS” or whatever their preference is.

If you decide you’re a utility-only frontend, then… there’s a great tool for that!

So now why on earth are you still plugging away at that utils.css?

Re: Why Tailwind CSS Won

#290

Earlier quoted context omitted.

Having a prebuilt consistent design system that you don’t have to build out for each project, arguing over defaults among the team is a lifesaver.

But you don't need Tailwind for that. A "designsystem.css" file with custom properties would do the trick. Without any added third party tech.

I tried to do that once. I decided to skip Tailwind and "just" bring in a few CSS variable that cover what I use.

By the 30th variable I stopped. The fact that I had to write significantly more boilerplate in CSS classes on top of that, helped me stop, too

Post reply on HN