Skip to content

Instantly share code, notes, and snippets.

@BenCavens
Created October 9, 2015 07:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BenCavens/1c794194eb454c6bda6a to your computer and use it in GitHub Desktop.
Save BenCavens/1c794194eb454c6bda6a to your computer and use it in GitHub Desktop.
sass general mixins
// Viewport sizes
$tablet-min-width: 768px;
$desktop-min-width: 1024px;
@mixin phone{
@media (max-width: #{$tablet-min-width - 1px}){
@content;
}
}
@mixin tablet{
@media (min-width: #{$tablet-min-width}) and (max-width:#{$desktop-min-width - 1px}){
@content;
}
}
@mixin desktop{
@media (min-width: #{$desktop-min-width}){
@content;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment