Live data from Hacker News

Tailwind Isn't for Me

spicyweb.dev

121–130 of 191 posts

Re: Tailwind Isn't for Me

#121
post #53
post #8

People want painkillers, not vitamins. That's why there is this endless flow of snake oil frameworks like Tailwind and all the others. People see some fancy demos and think "wow, so cool so easy" and "This is the newest framework, so it must be the best" and go for it. Then over time, they get caught in a web of problems that the complexity of the framework produces. Then a few people go for the vitamins route (plain…

Hmm, I’ve always considered tailwind like the spice to make css actually usable, kinda like elixir is to erlang, typescript is to javascript or C is to machine code. Its still CSS just the stuff that you _actually_ want to build is pre-packaged and thought out for the use case. And I’m not dissing on CSS - just those tools try to solve different problems. CSS is the ground truth, and it kinda has to support all the w…

What makes tailwind feel wrong for me is that you put the css classes everywhere exactly like you would set inline style attribute. I would prefer using the css slectors and select by an id or class name and apply a css like that. I avoid frontend but this is how I see it used in my team.

Would be nicer if you could do it like selector > color-xyz text0xyz paddifng-xyz and never add those classes inline

Re: Tailwind Isn't for Me

#122
post #116

As someone who used to make websites in the myspace days (and has about that much experience with web dev, plus a few static client sites from high school), I gave tailwind a try for my most recent project. I think it saves me a bit of time, and it's easier to get a decent aesthetic quickly. That said, I don't feel it's strictly necessary, and I don't like the HTML bloating either. It makes me want to create classes,…

Did you see that the person who wrote the article also created https://www.vanillabreeze.dev/ to remove dependencies from Tailwind?

Good to know!

Re: Tailwind Isn't for Me

#123
post #118
post #98

Earlier quoted context omitted.

This isn't about decision paralysis, but picking good names that other people will understand. But they won't, not all of them at least. No matter how great you're at naming things, you are going to do it differently than other people do. That doesn't matter on your personal home page, but it breaks down with a larger team. Inevitably, naming principles will drift apart, and after a few years, you'll have a mess. Don…

Why does the name matter? If it's a Wrapper or a Container or an InnerWrapper or whatever. It's just a 'label'.

Because there is a Stylesheet called main.css with 5000 lines, and somewhere in there is a block like this:

  .InnerWrapper {
    padding: 3px 7px;
    margin-left: -9px;
  }
The design just got a makeover, and you’re tasked with updating all buttons to have a wider spacing.

Good luck catching everything, including this class and its usages, without manually reviewing everything that is used like a button, inspecting the HTML, then going over the classes, one by one, without breaking some unintended side effect.

Re: Tailwind Isn't for Me

#124
post #61

Earlier quoted context omitted.

You... Can't. You literally cannot define a custom element without Javascript.

You don't have to define it, though. Browsers are supposed to just put unknown elements in the DOM and style them like any other element, using CSS.

Is this behavior specified by the standard? Any links to the relevant section?

Re: Tailwind Isn't for Me

#125

Earlier quoted context omitted.

I agree, it's exciting to have the industry trying gazillion things and see the survivors that get pushed into standards. It's much less exciting to have your project tied to frameworks (generic statement, not about Tailwind) that rot, requires massive rewrites on update, are unstable and forces you into non-standard stuff that tends to not interoperate well with the external world. I'm puzzled to see the popularity…

I feel we need a club for grumpy old men that yell at clouds! I'm only 34 but after 10 years doing this I now fully understand what my seniors were trying to teach me when I started. Boring technologies that work and will continue to work with the minimum of lock-in and fuss long into the future are what get me excited now.

I’m a bit older but I’m getting progressively more annoyed by this attitude of my peers, and increasingly think it’s an excuse not to learn new things.

I know plenty people that are stuck in Python and are some middle mangers and just yell bah! at everything new.

I’ve worked through the whole stack, am now heavily in elixir, work in a cutting edge LLM company and feel I’m better than I ever was. There’s a balance.

Re: Tailwind Isn't for Me

#126

Earlier quoted context omitted.

You don't have to define it, though. Browsers are supposed to just put unknown elements in the DOM and style them like any other element, using CSS.

Is this behavior specified by the standard? Any links to the relevant section?

The custom element specification (section 4.13) deals mostly with the registration and usage details, but the general extensibility section earlier on covers the basic use case: https://html.spec.whatwg.org/multipage/infrastructure.html#e...

"User agents must treat elements and attributes that they do not understand as semantically neutral; leaving them in the DOM (for DOM processors), and styling them according to CSS (for CSS processors), but not inferring any meaning from them."

Re: Tailwind Isn't for Me

#127
post #53

Earlier quoted context omitted.

Hmm, I’ve always considered tailwind like the spice to make css actually usable, kinda like elixir is to erlang, typescript is to javascript or C is to machine code. Its still CSS just the stuff that you _actually_ want to build is pre-packaged and thought out for the use case. And I’m not dissing on CSS - just those tools try to solve different problems. CSS is the ground truth, and it kinda has to support all the w…

What makes tailwind feel wrong for me is that you put the css classes everywhere exactly like you would set inline style attribute. I would prefer using the css slectors and select by an id or class name and apply a css like that. I avoid frontend but this is how I see it used in my team. Would be nicer if you could do it like selector > color-xyz text0xyz paddifng-xyz and never add those classes inline

Oh yeah it does feel weird “dirty” somewhat.

But to your suggestion - you can! Thats what components classes do in essence. When you have a bunch of styles that _always_ go together - you bunch em up.

But in practice it is usually simpler to keep the classes and use other templating features of your platform to achieve this.

It becomes extremely nice as every time you need the question “why is my html look like this” answered, there is no hierarchy of other files to dig through - its all just there.

And as with any tool you can abuse it in ways that are not intended - seen plenty of ugly tailwind examples with tons of weird unruly code. But thats even more true for css itself. Omg the horrors I’ve seen with custom raw css cans still give me nightmares.

Re: Tailwind Isn't for Me

#128

This from 2021. No criticism, it is a good post. I was just confused at first and only realized it when I came about the part mentioning the JIT. This is a hill I will die on: Blog posts should have a date at the top.

And the HN title should include (2021)

Re: Tailwind Isn't for Me

#129
post #8

People want painkillers, not vitamins. That's why there is this endless flow of snake oil frameworks like Tailwind and all the others. People see some fancy demos and think "wow, so cool so easy" and "This is the newest framework, so it must be the best" and go for it. Then over time, they get caught in a web of problems that the complexity of the framework produces. Then a few people go for the vitamins route (plain…

As a developer from ancient times.. yes!

Re: Tailwind Isn't for Me

#130
post #126

Earlier quoted context omitted.

Is this behavior specified by the standard? Any links to the relevant section?

The custom element specification (section 4.13) deals mostly with the registration and usage details, but the general extensibility section earlier on covers the basic use case: https://html.spec.whatwg.org/multipage/infrastructure.html#e... "User agents must treat elements and attributes that they do not understand as semantically neutral; leaving them in the DOM (for DOM processors), and styling them according to C…

Yes. It means they are not "custom elements". They are basically divs.
Post reply on HN