DEV Community

Discussion on: Grid vs Flex: Where to use which? šŸ¤”

Collapse
 
banesto profile image
Ernests Kečko • Edited

I am sorry, but it's really funny how you debunk a "flex for 1D layout and grid for 2D layout" myth and then present examples to confirm said "myth". If you ask me, it's a rule of thumb not a myth. The fact that flex can span over two lines when not enough space does not mean it's 2D, same as grid consisting of one row does not mean it's 1D.

It's like debunking "car is for driving, plane is for flying" myth by saying that car can fly off the ramp & plane is certainly driving on a runway.

Collapse
 
ruppysuppy profile image
Tapajyoti Bose

Perhaps I should have added details, but you can even style how the items are displayed in multiple lines using align-content. For details check out: dev.to/ruppysuppy/flexbox-decoded-...