Hacker News new | past | comments | ask | show | jobs | submit login

That reminds me of the old trick of using a 1x1 pixel in an empty table cell to ensure that internet explorer would actually expand the table cell to whatever width you set it to (height still needed another trick if i recall correctly).   would work, too, but then the minimum height of the cell would be whatever the line height was set to, and the line-height property didn't behave the same across browsers.

It's funny how old tricks make a comeback. I see a lot of  's in React codebases to preserve whitespace around JSX tags.




And the old trick of a 2x2 pixel gif with one colour transparent, and the other a non-transparent colour which, when set as a background to the table cell, provided an illusion of colour transparency with the main background behind the table.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: