Live data from Hacker News

Why Tailwind CSS Won

matt-rickard.com

21–30 of 559 posts

Re: Why Tailwind CSS Won

#22
Yea Tailwind is so good. Yes you have to enter more class names into your html, but the payoff is you don't need to mess about with CSS at all unless you need something very specific.

It also makes it so much easer to progressively update things to a new design, without worrying about 1 change in a CSS file potentially having an effect anywhere.

Re: Why Tailwind CSS Won

#23
post #8

For me it won because I view tailwind as vanilla CSS with a nicer syntax (mostly) and sane defaults that makes your website look decent out of the box. With the prettier autosorting plugin, the classes are ordered in a predictable fashion, making it easier to read than one would imagine. It's not a perfect replacement for vanilla CSS and I still fall back down to writing plain old CSS for stuff like box shadows or mo…

Tangential, thinking aloud: The "default" (no css) look of HTML pages with black on white Serif text with default paddings / margins / spacing...must also have been picked at the time to make web pages look pretty (in a generic sense) out of the box? Just that we have now evolved in our sense of visual design tastes / whats possible has changed over the decades, maybe.

The default looks like a Physics paper from the 80s because it was made to render Physics papers from the 80s.

Re: Why Tailwind CSS Won

#24
post #11

I don't get Tailwind. In my book, CSS is here to facilitate the style of multiple webpages by modifying a set of rules, and classes are here to mutualise said rules. With Tailwind, it looks like you design by writing HTML, which is the opposite of what CSS aims at. So if you wish to change your design, you'll have to update multiple templates instead of one CSS rule. Every time I've had to work with Tailwind, it felt…

I can sum up what I like about Tailwind in the following code:

    ``` (in CSS)

    a.link {
      border: red;
    }

    a.link:hover {
      border: blue;
    }
    ```

    ``` (in Tailwind)
    
    ```
It's much easier in Tailwind for me to see locally what's going on with that styling. If I lived in this code all the time, or I was good at structuring CSS, then maybe the first would be more appealing. But I'm a shit at CSS, it always turns into an unmaintainable mess, and I look after a lot of different projects that I might not touch for 6 months. So Tailwind's approach is easier for me.

Re: Why Tailwind CSS Won

#25

I'm using Bootstrap in a Tailwind kind of way, with many utility classes. I don't use it's container system. How do you get a basic Tailwind design running? It seems like you need a Bootstrap equivalent on it anyway.

There is a persistent misconception that Tailwind competes with Bootstrap, but they just exist at different levels. Bootstrap provides components, but Tailwind is just a faster way to write CSS.

Re: Why Tailwind CSS Won

#26
Once again, the "write once lots of small websites" people and the "maintain huge web apps" people, will be talking past each other.

We share a base layer in HTML, CSS, JS, but the incentives, requirements, job environments, team sizes, couldn't be more different.

I wonder about other languages and ecosystems. What would be a similar situation for e.g. C? Is there such a thing?

Re: Why Tailwind CSS Won

#29
post #11

I don't get Tailwind. In my book, CSS is here to facilitate the style of multiple webpages by modifying a set of rules, and classes are here to mutualise said rules. With Tailwind, it looks like you design by writing HTML, which is the opposite of what CSS aims at. So if you wish to change your design, you'll have to update multiple templates instead of one CSS rule. Every time I've had to work with Tailwind, it felt…

In a recent thread someone explained Tailwind was best used with component frameworks, and that made it make a lot more sense and I could see the appeal.

It is easier to write CSS with Svelte.

Re: Why Tailwind CSS Won

#30
post #11

I don't get Tailwind. In my book, CSS is here to facilitate the style of multiple webpages by modifying a set of rules, and classes are here to mutualise said rules. With Tailwind, it looks like you design by writing HTML, which is the opposite of what CSS aims at. So if you wish to change your design, you'll have to update multiple templates instead of one CSS rule. Every time I've had to work with Tailwind, it felt…

I think the framework is meant to be used by other frameworks and not by humans.

It is an unpleasant chore if you use it by hand and I have given up on it but I can see that if it's just used in components and then html is not written by hand but made dynamically it could work better.

It's basically a CSS framework for JS frameworks and not for writing HTML.

Post reply on HN