Answers for "horizontal center all items in div"

CSS
10

css center

/* this will center all children within the parent element. */
.parent {
  display: flex;
  justify-content: center; /* horizontal */
  align-items: center; /* vertical */
}
Posted by: Guest on May-17-2020

Code answers related to "horizontal center all items in div"

Browse Popular Code Answers by Language