Skip to content

Instantly share code, notes, and snippets.

@Solomko2
Created July 14, 2015 13:25
Show Gist options
  • Save Solomko2/08e63ce1e20f37d9a26a to your computer and use it in GitHub Desktop.
Save Solomko2/08e63ce1e20f37d9a26a to your computer and use it in GitHub Desktop.
make bootstrap grid
<div class="row">
<div class="col-xs-12 col-sm-6 col-md-4 col-lg-2">Meow</div>
<div class="col-xs-12 col-sm-6 col-md-4 col-lg-2">Meow</div>
<div class="col-xs-12 col-sm-6 col-md-4 col-lg-2">Meow</div>
<div class="col-xs-12 col-sm-6 col-md-4 col-lg-2">Meow</div>
</div>
And this is self compiled:
.productgrid {
.make-row();
.clearfix;
.product {
.make-xs-column(12);
.make-sm-column(6);
.make-md-column(4);
.make-lg-column(2);
}
}
The result markup will look like this:
<div class="productgrid">
<div class="product">Meow</div>
<div class="product">Meow</div>
<div class="product">Meow</div>
<div class="product">Meow</div>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment