Hacker News new | ask | show | jobs
by forgotmypw17 1163 days ago
I think tables for layout are severely underrated...
6 comments

Fun fact: Hacker News itself is structured predominantly with tables. Every comment/thread creates a new table nested within the context of its parent's table. It's tables all the way down.
Until you get to the turtles...
Tables are reliable. Css is insane. It is hard to track down where a style is coming from.
1. Can't you just use the style inspector in your browser?

2. Imo, Grid is a much easier to read alternative to most uses of tables.

Tables does not render reliably across platforms. This is because the algorithm for sizing columns and cells was never standardized.

Back when tables were the only tool available for layout, professionals combined tables with 1x1 pixel transparent gifs which could be scaled to force cells to have a fixed size.

I guess you could argue that tables combined with spacer-gifs are reliable. But solution exists which are just as reliable, much easier to use, and better for accessibility.

> It is hard to track down where a style is coming from.

This is an orthogonal concern. If you don't like CSS inheritance and cascade, you can just use style attributes directly on elements. I believe Tailwind uses a similar approach through class attributes.

I beg to differ. Nothing more miserable than debugging email templates with tables nested to the x-th degree.
Fair enough.

Despite the headline, it really isn't the important part. The important thing is getting rid of the mso styling.

4 hours as of this comment and nobody has mentioned the real reason (accessibility) that tables were ditched for CSS?

I'm getting fuck old...

(I like table layouts, now git off mah lawn ya green youngins.)

tables have some annoying edge cases, like e.g. they interact poorly with responsive images