Implementing Vertical Centering in CSS


Vertically center content using Flexbox, a common design task.

Source Code

.centered-content {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 200px;
}
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments