The Holy Grail Layout using CSS Grids(bitsofco.de)

over 4 years ago from Ire Aderinokun, Designer, Developer

  • Jim SilvermanJim Silverman, over 4 years ago

    i'm not seeing any advantages over flexbox, only additional complexity. did i miss something?

    0 points
    • Floyd WilliamsonFloyd Williamson, over 4 years ago (edited over 4 years ago )

      I have to take a closer look, but one advantage seems to be more control over the number of columns per row. I was making a periodic table in flexbox, and needed 18 columns per row. Flexbox does not really have a simple solution for this, and I needed to use a combination of margins and something like width: calc(5.5555555556% - 6px);.

      CSS grids solution? According to this article, perhaps something like: grid-template-columns: repeat(18, ?);

      0 points