Centering

This is part of the Semicolon&Sons Code Diary - consisting of lessons learned on the job. You're in the css-and-design category.

Last Updated: 2024-05-04

To get an element (e.g. a button) to center by putting text-align: center on its parent. Needs no width given.

Or set margin auto on the x axis.