Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> > To this day it is the only way to vertically center elements.

> Not true anymore (edit: didn't see the 2014) but the productivity cost of not being able to just "vertical-align: middle;" inside divs for the last 30 years must be billions of dollars.

Even back then (possibly even back in the 90s? I know this existed in the 2000s) we had "VALIGN=MIDDLE" inside table cells.



Right, people seem to forget that table-based designs ruled the roost in the 90s and early 00s.

All of the vertical align, layering, etc hacks came from people not wanting to use tables anymore and divs (and other block elements) finally becoming more usable. Those hacks were the growing pains of an entire shift in paradigm.


Tables made much more intuitive sense than something like flexbox now but that came at the expense of being a nightmare to maintain.

Trying to hack a table layout together often led to frequent edits and initial attempts to maintain clean layout comments ended. You're left with never ending <tr><td><tr><td><tr><td> that you hopefully at least indented to maintain sanity. But god help you if your stumbled into another person's table layout code...

Spending time just entering "here", saving the file, and seeing where the "here" shows up. By the time 5pm rolled around "here" often turned into something like "ass" or "fuck", or if it's really bad "fuck you". IYKYK


I didn't say the transition was a bad one. I said that there was a decade or so of warts + growing pains as HTML and CSS grew to accommodate freeform block layouts. It wasn't until HTML5 + CSS3 that it was super usable, and until Flexbox that it became somewhat easy.


Was it any worse than nested div soups?


In some ways. There was at least a logical organization around a table, as long as you could wrap your head around all the markup and maintain it. Nested divs with CSS felt like you sometimes be halfway down a road that will never lead to where you want to go.


"table-based designs ruled the roost in the 90s and early 00s"

Have you checked how HN does layout?


No longer being preeminent doesn't mean non-existent.


Honestly it often feels like HTML and CSS evolutions were two steps forward, one step back.

Like, cool that we can now do rounded corners in CSS but why can't I vertically align in a div yet? (this was before flexbox)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: