| ▲ | psygn89 5 hours ago | ||||||||||||||||||||||
Yeah, to expand on that... Flex is, well, flexible, whereas Grid is more rigid like a table. The rigidity of Grid allows you to span rows and columns (2D) just like you can with table cells (colspan/rowspan). Grid is usually used at a macro level for its more deterministic layout (no unintuitive flex quirks), while flex is usually used to lay things out at a component level where you don't care that the next row of items isn't perfectly aligned with the ones above (you will often see it hold some buttons or badges, or vertically align text to an icon), and Grid setting the layout of the app and container components (modals, cards, etc). | |||||||||||||||||||||||
| ▲ | taftster 4 hours ago | parent [-] | ||||||||||||||||||||||
So is Grid supposed to be what we should use to replace the html <table> element? That I still use to this day for layouts because CSS still sucks to me? | |||||||||||||||||||||||
| |||||||||||||||||||||||