DEV Community

Discussion on: How I learned to stop worrying about the margins and love the gap

Collapse
 
grahamthedev profile image
GrahamTheDev • Edited

Maybe hang fire on using it in production or find a polyfill for now, gap in flex only has 72% coverage (for example on most iOS devices it doesn't work, although that should fix itself in about 6-12 months as people update).

Great one for future proofing but not quite usable yet unfortunately!

Instead use grid gap perhaps? Grid gap has much better coverage

Collapse
 
mattcoady profile image
Matt Coady

Yes! Absolutely, like all new web features make sure it meets your project standards for usability.

As you mentioned as well this:

nav {
  display: grid;
  grid-auto-flow: column;
  grid-gap: 10px;
}
Enter fullscreen mode Exit fullscreen mode

...should produce the same results.