Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
TheOtherHobbes
· 7mo ago · 0 comments
Does
anyone
know how to centre a div?
Last time I looked there were at least seven ways to do it.
Comments
[–]
bdangubic
7mo ago
I think "How to center a DIV" was at the top of HN
way more times
than it should have been :)
[–]
papa0101
7mo ago
margin: auto, or flex align-items/justify-content are my go-tos
[–]
queenkjuul
7mo ago
Flexbox, mate