w3 schools making components in the center in html code example
Example 1: css align center
//HTML
Hello World
//CSS
.parent {
display: flex;
justify-content: center;
align-items: center;
}
Example 2: align center css
margin: auto;
//HTML
Hello World
//CSS
.parent {
display: flex;
justify-content: center;
align-items: center;
}
margin: auto;