Columns vs grids in flex section

rickNweg Member Posts: 4
edited August 2023 in Ask a Question

Hey, can't I have a grid in a flex section any more? Am I supposed to use multiple sections when I want to layout a new row? Or should I use a advanced flexbox inside a single flex column?

In "flex 1.0 section" I could have a "grid" and then go from there. Now I can only have "flex columns" in a "flex section". So if I e.g. want a layout where elements overlap vertically, I have to use stacking of flex elements that do not really work responsive across breakpoints.

Thanks for any hints…



Best Answer

  • ScottyStrehlow
    ScottyStrehlow Member Posts: 318 Duda Staff
    Answer ✓

    Hi @rickNweg,

    I do have a solution for you!

    It's correct that we no longer have “grids” in Flex, indeed this belongs to Flex 1.0, for the new Flex we are using Section (for rows) and Flex columns (for columns). So if you'd to have overlapping elements, you can add an Advanced grid inside a Flex column.

    Check out this short screen recording below:

    I hope that helps clarify!


  • louisbarnett
    louisbarnett Member Posts: 1

    i'm wondering the same! not sure what happened to the grids, feels like flex 2.0 has gone backwards from 1.0