this post was submitted on 11 Aug 2023
486 points (96.9% liked)

Programmer Humor

36963 readers
178 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 
all 21 comments
sorted by: hot top controversial new old
[–] odium@programming.dev 74 points 2 years ago (4 children)

z-index: 999999 !important;

[–] maeries@feddit.de 43 points 2 years ago

!didistutter?;

[–] sbv@sh.itjust.works 28 points 2 years ago (1 children)
[–] Xylight@lemmy.xylight.dev 36 points 2 years ago (2 children)

fun fact: !important !important is essentially !importanter, and you can go even further if you want a hell of a css hierarchy

[–] whatisallthis@lemm.ee 14 points 2 years ago (3 children)

You can also just write your class again as some sort of additional specificity like

.myclass.myclass.myclass { color:red !important !important; }

[–] FUsername@feddit.de 6 points 2 years ago (1 children)

The fact that this and the prior comments work don't make like CSS more tbh

[–] MellowSnow@lemmy.world 2 points 2 years ago

Like most things in the world of dev, there are right and wrong ways to do things. Just because you can doesn't mean you should! CSS can be quite nice when used correctly!

[–] havocpants@lemm.ee 0 points 2 years ago

this and the parent comment have blown my mind.

[–] lukas@lemmy.haigner.me 1 points 2 years ago

This... exists? This is horrible.

[–] AlecSadler@lemmy.ml 17 points 2 years ago (1 children)

I actually encountered an issue earlier today where my important wasn't working...and it was because another dev had already added a more specific important.

I deleted their important.

[–] SnowdenHeroOfOurTime@unilem.org 8 points 2 years ago

I support this. Assert dominance.

[–] GombeenSysadmin@feddit.uk 2 points 2 years ago (2 children)

When I read that, I can never not say “not important” in my head

[–] hellishharlot@programming.dev 3 points 2 years ago

Yeah I think that makes CSS a manager. It's always prioritizing not important things

[–] cs127@lemmy.sdf.org 45 points 2 years ago* (last edited 2 years ago)

the z index is so high that the div escaped your monitor and is behind your head now

[–] SpaceNoodle@lemmy.world 21 points 2 years ago

"programmer"

[–] _hovi_@lemmy.world 10 points 2 years ago

Always forget the position: relative

[–] TheYear2525@lemmy.world 5 points 2 years ago (1 children)
[–] whatisallthis@lemm.ee 1 points 2 years ago

Along with transforms being 3d or flat transform styles