47
Ten Lines Of Code That Changed My World
(pixelambacht.nl)
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Follow the wormhole through a path of communities !webdev@programming.dev
This should be:
outline: 10px solid hotpink;.Borders are calculated as part of the layout, so adding or changing a border also means potentially changing the layout. So just by trying to debug something, you're potentially making the problem worse. It's a heisenbug.
On the other hand,
outlinedoesn't change the layout, it's drawn around the element. Also, you can usually see what the border was on the element which makes it easier to debug all that nested div slop that bootstrap/tailwind vibecoders like to produce. And, you can also offset the outline if you need to also see the borders of elements touching the one you're trying to debug.I'm a
fill: #ff000066;kinda guy personallyDid you mean something else?
fillis only for svgs.But my personal variants are:
outline: 3px solid red;andoutline: 3px solid #F0F;just because they are such obvious debug/programmer-art coloursOpe you're right, I meant
background-color. In my defense I was working with svg styling more recently than html. What can I say, I'm nothing without my linter haha