Skip to content

Instantly share code, notes, and snippets.

@zuDevonRW
Created April 27, 2018 11:43
Show Gist options
  • Save zuDevonRW/b40968ac95fda5f1429097216e593b47 to your computer and use it in GitHub Desktop.
Save zuDevonRW/b40968ac95fda5f1429097216e593b47 to your computer and use it in GitHub Desktop.
$supportsGrid: TRUE;
@mixin supportsGrid() {
@if $supportsGrid == TRUE {
@supports (display: grid) {
@content;
}
}
}
/* usage */
.thing {
display: inline-block;
@include supportsGrid {
display: grid;
grid-template-columns: 1fr 1fr;
grid-column-gap: 24px;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment