CSS isn't magic
Subscribe
Sign in
Home
Archive
About
You missed this super obvious way to display elements in a column
There is the super short way to display elements in a column.
Nov 5
•
Stas Melnikov
October 2025
CSS without order dependence
A problem with rule order with the same specificity is noticeable when we have one component with a few modifications.
Oct 29
•
Stas Melnikov
Сustom checkboxes are on steroids with :has()
The next-sibling combinator has one disadvantage.
Oct 22
•
Stas Melnikov
height 100dvh wins height 100vh
If we use vh units for the height property it won’t consider mobile UI bar size changes.
Oct 15
•
Stas Melnikov
Read the all CSS isn't magic posts right away
When is using display: block for ::before or ::after unnecessary?
Oct 9
•
Stas Melnikov
aspect-ratio is a page jump pill
Page jumps after loading pictures is a pain.
Oct 8
•
Stas Melnikov
Focus styles aren't equivalent to hover styles
Focus styles can’t be equal to hover styles because in this case users have to understand a focus state for every element.
Oct 1
•
Stas Melnikov
This site requires JavaScript to run correctly. Please
turn on JavaScript
or unblock scripts