Earlier quoted context omitted.
If you work with components, you don't have this problem. If you don't work with components, good ol' search and replace and it's done.
If you work with components then why not just use CSS?
Why Tailwind CSS Won
131–140 of 559 posts
Re: Why Tailwind CSS Won
#132Re: Why Tailwind CSS Won
#133I do constantly shudder though when reading a list of class names like this:
> fixed inset-y-0 right-0 z-50 w-full overflow-y-auto bg-white px-6 py-6 sm:max-w-sm sm:ring-1 sm:ring-gray-900/10
Re: Why Tailwind CSS Won
#134Earlier quoted context omitted.
> class="my-4 mb-sm-5 mb-lg-6" I've seen Perl code that was more readable than this.
If you know the convention it's quite easy. I don't know Tailwind but with Bootstrap it would be m = margin, y = y axis, b = bottom, sm/lg = screen size, 4/5/6 = size
Re: Why Tailwind CSS Won
#135Earlier quoted context omitted.
Tailwind is also great for this. You create components with Tailwind that make this trivial
"trivial"? So I still have to componentize my presentation layers to do tailwind "correctly", but instead of writing CSS in readable multiline chunks in a language every developer already knows, I need to use this cryptic one liner in any order that literally nobody can read? What in the hell is wrong with this industry? Sometimes clever ideas aren't all that clever. Sometimes they're just dumb.
Re: Why Tailwind CSS Won
#136I always felt slightly dirty after writing a bit of inline CSS (`style=”color: red“`) instead of a proper class, yet at the same time it accomplishes the goal and it was fast. So this is basically Tailwind, right?
It’s impossible to write a media query or target a child with inline styles. With tailwind, the first one is encouraged and the second is at least possible, and in some scenarios, encouraged (group hover).
Re: Why Tailwind CSS Won
#137Re: Why Tailwind CSS Won
#138I'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.
Probably not granular enough for Tailwind fans though.
Re: Why Tailwind CSS Won
#1391. 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 the box, and very easy to customize.
3. And, most importantly, it allows for easy art direction. Does one button need to be a slightly different size or color for this one specific element? Chuck an extra modular class on it. No need to build a complex cascasding or edge cases. (Shout out to `tailwind-merge`)
Point 3 for me speeds up production work immensely. Also, not being in JS has shrunk bundle sizes by a small amount, which is always welcome in this era.
Re: Why Tailwind CSS Won
#140It's as modern as the style parameter is, and it's as reusable as a moving a dirt pile from one corner to the next.
You're not learning anything valuable by learning Tailwind. Learn CSS, that will stick with you for the next 20 years.
It amuses me when a library is implemented 'with tailwind', which means it's totally useless to the people _not using tailwind_, and excruciating to clean up.
Go ahead, downvote me to hell, I'll see you in 5 years.