Skip to content

Instantly share code, notes, and snippets.

@briznad
briznad / grid.scss
Created November 3, 2018 21:28
better sass grid
@function _grid($columns, $total-columns: 12, $breakpoint: small, $external: true) {
$gutter-compensation: null;
$gutter-width: map-get($grid-gutters, $breakpoint);
@if $external {
$gutter-compensation: $gutter-width * 0.5;
} @else {
$gutter-compensation: $gutter-width * -1;
}