News for hackers. Stuff that matters.
Re:Use spacer components instead of CSS margins (2020) by wildpeaks on Tuesday January 04, 2022 @10:32AM (#29795801)
I'd strongly advise learning what modern CSS can do thanks to grid, flex, column-count, gap, and rem units before bloating DOM tree diffs with empty div tags.
Re:Use spacer components instead of CSS margins (2020) by nrbernard on Tuesday January 04, 2022 @12:41PM (#29797487)
Exactly. It seems like the conclusion of the post should really be: don't apply layout styles to elements if their parent elements are responsible for layout.