1. Home
  2. Css
  3. Align to center
#css#flex

A quick way to center content horizontally and vertically using flex.

<style>
    .container{
        display: flex;
        align-items: center;
        justify-content: center;
    }
</style>
copy
Full Css cheatsheet
Sitemap Git repository