Skip to content← All gravesR.I.P.
The div that refused to center
–
“Stood slightly to the left of everything, forever.”
CSSCSS
Death certificate
- Status
- 🪦 Buried
- Cause of death
- CSSLooked perfect in one browser, then met the others. `!important` was not enough.
- Severity
- Low
- Hours to kill
- 6 hours
- Killed by
- Jashanpreet
- Language
- CSS
- Born
- 5 Aug 2024
- Fix merged
- 9 Aug 2024
- Buried
- 19 Aug 2024
- Component
- layout
- Symptoms
- The login card sat a few pixels left of centre on every screen size.
- The fix
- Replaced the margin hacks with a flexbox wrapper.
Timeline
Every life of this bug, oldest first.
- 🐛
Born as “The div that refused to center”5 Aug 2024
- 🩹
Fix merged9 Aug 2024
- 🪦
Buried19 Aug 2024