Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Generated by SassMeister.com.
// ----
// Sass (v3.4.14)
// Compass (v1.0.3)
// ----
%yes-extend{
background: url(http://www.placekitten.com/209/200) no-repeat;
}
%no-extend{
background:no-kittens;
}
@mixin my-mixin($val1, $val2:1em, $val3:false){
color:$val1;
font-size:$val2;
@if $val3 { @extend %yes-extend; }
@else { @extend %no-extend; }
}
.my-class{
@include my-mixin(green);
}
.my-class {
background: no-kittens;
}
.my-class {
color: green;
font-size: 1em;
}
<a href="#">Red</a>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment