Hacker News new | ask | show | jobs
by Joker_vD 19 hours ago
You know, this speaks volumes. Layout is a complicated business, sure, but CSS just keeps having monumental shifts in how you're supposed to approach it year after year; it's as if it's done without any overarching theory/vision but merely groping in the dark, trying things and fixes, and seeing what sticks and doesn't suck too horribly (this latter part is optional; remember Yandex's BEM?)
3 comments

You really don’t have to change your css. My personal website has been using roughly the same css for a decade. Why not?

Sure if you are a designer and want to follow trends, you’ll have to keep your css skills up to date. But for most websites, you can use css from a decade ago.

Would you prefer that CSS never evolve, and our frustrations remain the same? Writing CSS today has gotten significantly easier with flexbox, variables and now nesting. BEM is not part of the CSS spec, that's just a design methodology.
I would prefer it to finally figure things out properly, and then just stop changing, yes.

> Writing CSS today has gotten significantly easier with flexbox, variables and now nesting.

Which, you know, are not some technically complicated ideas that simply could not have been done thirty years ago. Heck, <table> existed, and so did the algorithm that laid it out, from the outset yet getting flexbox to replicate that functionality took literal decades. And nesting is in no way more complicated to implement than cascading.

> BEM is not part of the CSS spec, that's just a design methodology.

Yes, and it existed for a reason, to paper over the deficiencies of the built-in functionality.

at least it changes less than js frameworks
We're going on 13 years since React launched publicly
17 years for flexbox