Hacker News new | ask | show | jobs
by dennisbest 3971 days ago
Just use flex-box. And by "use", I mean get ready to study it, change the way you write CSS, give it all of your worldly possessions, and eventually collect money for it at the airport.
5 comments

I thought the css-tricks page did an incredible job of both explaining the concepts and laying out the information in such a way that it makes a great quick reference once you've gone through it.

https://css-tricks.com/snippets/css/a-guide-to-flexbox/

<div style="display:flex;justify-content:center;align-items:center;"> <div></div> </div>

?

Maybe the OP meant their description in a... well... positive way?

Certainly, flex-box addresses a problem that's been making CSS writers frustrated for a long time.

That is, assuming you don't need to support older browsers like ie9 or ie8...
This is one of those things you really, really deeply have to question. How much money (via dev time) do you spend on supporting such very old legacy content vs the derived value of said customers? Some people DO have that use case, and for them it is their lot to suffer. But that's clearly not he story presented in the link.

Same deal with mobile OS support, really. You have to have a pretty unusual or long-standing audience to support anything pre-4.2, let alone pre-4.0. iOS7 is also probably not worth the time to target for most products.

or ie10...
IE10 supports flexbox, it just supports the 2012 syntax.
Don't get me wrong. I love flex-box and use it. But I keep a bookmark to the CSS Tricks guide handy. :)