3 ms·
No, you have to vertically center it as well. Horizontal centering is fairly easy even with flex-box.
by lisper 12y ago
No, you have to vertically center it as well. Horizontal centering is fairly easy even with flex-box.
- simcop2387 12y agoThis does appear to be vertically centering it, at least in Firefox.
- sim0n 12y agoThat does vertically center the content.
- nostrademons 12y agoVertically centered on Chrome Mac as well. Safari (and IE) still requires a vendor prefix to use flexbox, but with that added, it works in Safari as well: https://jsfiddle.net/k281a8v0/ https://jsfiddle.net/k281a8v0/
- lisper 12y agoCongratulations, yours is the first solution I've seen that actually works.