Skip to content

Instantly share code, notes, and snippets.

@scottkellum
Created June 5, 2012 14:48
Show Gist options
  • Save scottkellum/2875452 to your computer and use it in GitHub Desktop.
Save scottkellum/2875452 to your computer and use it in GitHub Desktop.
Sass collection

SCSS

$breakpoint: 600px;

.foo {
  color: #333;
  width: 100%;
  @collect $breakpoint {
    width: 50%;
    float: left;
  }
}

.bar {
  width: 100%;
  @collect $breakpoint {
    width: 25%;
    float: left;
  }
}

@media (min-width: $breakpoint) {
  @deposit $breakpoint;
}

CSS

.foo {
  color: #333;
  width: 100%;
}

.bar {
  width: 100%;
}

@media (min-width: 600px) {
  .foo {
    width: 50%;
    float: left;
  }
  .bar {
    width: 25%;
    float: left;
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment