this post was submitted on 22 Dec 2025
282 points (96.1% liked)

Programmer Humor

28021 readers
1536 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] cbazero@programming.dev 17 points 2 days ago (2 children)

If you need to be good at a layout language to center something, then maybe the layout language sucks.

[–] irelephant@programming.dev 4 points 1 day ago (2 children)

You literally just have to give it a width and add margin: 0 auto;

[–] humorlessrepost@lemmy.world 1 points 8 hours ago* (last edited 8 hours ago)

I think it’s implied they’re talking about centering both horizontally and vertically. And probably with unknown height.

Still easy these days , though.

[–] Witchfire@lemmy.world 1 points 1 day ago* (last edited 1 day ago)

Or use Flexbox

But your solution works as well for simple cases

[–] TrickDacy@lemmy.world 9 points 2 days ago

What it says is zero knowledge on the part of the whiner.