With that said, your premise is correct. Prevention is uncool, and safety seems overbearing, preparation is met with "YAGNI". Until people need it.
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 weird edge cases and uses that tailwind doesn’t.
Tailwind is like usability overhaul of css, but still allows you to “drop down to css” everywhere you want to.
It can compose like css, but it also constraints you to what you can do. It also gives you tools to group, adjust, refine styles, but in a usable way.
It’s a transpiled language on top of css, but more ambiguous than sass or less.
Given enough time most projects I work with slowly gravitate towards small composable utility classes anyway, tailwind is just logical evolution of that.
And since design peojects usually gravitate towards design systems in the long run, tailwind is really good at facilitating that.
Would be nicer if you could do it like selector > color-xyz text0xyz paddifng-xyz and never add those classes inline
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.
I personally believe the js model is completely wrong for the browser and something like an actor model would fit much better.
I’m not saying we should jump on every hype train, and personally really dislike the react ecosystem but I also think we should encourage exploring new approaches. CSS, html and js evolution is driven by the exploration of these new frameworks and they’re very different than what they were just a few years ago
I'm puzzled to see the popularity of such frameworks while boring technologies often are well documented, well tested, highly stable, provide acceptable dev efficiency, readable by any dev, and often comes with much better performance.
I'm probably just a grumpy old man yelling at clouds.
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 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.
I've shifted career and work as a photographer now, so remain ultra-conservative in my technology choices because I know I don't want to expend the time and mental energy to adopt over-complex solutions. It's less about how old/new they are, and more using the right tool for the job.
PS: Glad to see Elixir cropping up more and more. I loved using it before I changed careers, and still keep tabs on it. I've got an idea for a small API/service that might benefit my work, and unless I stumble upon a more appropriate choice, it'll likely be based on Phoenix.
I like learning new things but the industry shouldn't follow latest trends for any project. https://boringtechnology.club/
I can see a top tier game engine developer talking with skepticism about current web tech, but it's more often coming from something like enterprise java devs from the 2000s that used to take months fudging with class hierarchies to deliver a basic form GUI. The kind that must take any opportunity to denounce electron apps but would never give up VS Code and go back to Eclipse.
CSS is not static. It has been getting better and better all the time and keeps improving.
it only took ~20 years to get a working vertical align (which was available in HTML from basically day 1, might I add). similar for grid to be available and it still kinda sucks.
There are frameworks that genuinenly improve the development experience for certain uses cases. As with many things, it's important to still now the basics (in this case, CSS), but why not use Tailwind if the philosophy aligns with yours and makes you more productive?
Sure, switching frameworks ever few months to try the hottest shit out there is also not great, and many people overuse frameworks (e.g., React is an overkill for many (most?) applications I have seen). But that doesn't mean there isn't merit in frameworks.
For a long-term project that will require lots of development a more thorough approach would be justified.
I'm very much in agreement with the author (regarding Tailwind, I'm Web Component-curious but yet to be convinced to the degree is obviously is...). I started with Adam Morse's "Tachyons" library which is the pre-cursor to Tailwind. Conceptually that worked for me, particularly because I was all-in on the JS ecosystem, building a startup with React and Meteor (story for another time). I wrote up my thoughts on a now-extinct blog [1].
Over time though I found JS to be a fragile and brittle ecosystem to work in; I'm sure as many others have. I not only moved away from SPAs and JS as my backend language of choice to avoid npm dependency hell, but also any JS build tools because using the latter is functionally equivalent to the former.
When my choice of language/framework at the time (Elixir & Phoenix) added support for Tailwind by default, without a JS build tool (handled by an Elixir lib) I was conflicted. I had gotten used to vanilla CSS again with all the new additions such as custom properties and wasn't convinced I needed Tailwind. Even though it didn't bring the JS build chain I hated, it still represented a hard dependency to replace down the line if required, and still required a build tool. It was potentially a decision future me would regret. These days I'm all about not snookering future-me.
I think Tailwind has it's place where you're already using a build tool that can support it (JS or otherwise) and you're working in a team that needs a design system straight out of the box. It gets you up and running quickly (particularly with their TailwindUI components and themes) and provides a point of reference for everyone working on the project without coming up with a design/token system of your own. But that can be said of the older frameworks like Bootstrap or Zurb Foundation (remember that?!).
Personally I'm very happy writing HTML, CSS & JS without any build tools, bar a bit of templating to bring in partials here and there. Admittedly I'm working on very different websites now, but I spend years thinking that the foundations of the web needed augmenting and abstracting away (they probably did at that point...), but now I'm quite happy to work with it in it's natural state.
[1]: https://github.com/jamiedumont/personal_zola/blob/main/conte...
I haven't used tw yet, but I intend to because I was blown away by how much sense the authors' book Refactoring UI made.
Which condition do you intend to treat by taking multivitamins?
Have you looked at randomized controlled studies and found that they support your idea that taking MVs has a positive effect on that condition?
Have you got your bloodwork done? Did the doctor then suggest that based on your situation MVs are the right approach? I never have heard of such a thing happening.
So yeah, TW and MVs are similar. Both appeal to people who think "Hey, why do the work and figure things out and act appropriately? I can just swallow this magic pill!".
If someone's good at, fast at, and enjoys writing vanilla css, it might be the way to go, but if they don't have a sense of design or lack skill in writing CSS, a framework allows pages to look professional quickly.
A site made with a css framework may not be as extensible as one made with vanilla css, but if there's strong enough desire it could always be taken out and swapped for vanilla CSS.
For quickly getting things done on projects where time/resources are , I'd go for a frame work (for the reasons above: I lack a sense of design and would spend an eternity tinkering and doubting my design choices).
Not true at all. It ensures people get needed nutrients when they have shitty diets. It's not snakeoil at all.
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 html+css+js) and most go for the next painkiller on the market.