Created
March 6, 2014 22:04
-
-
Save bigandy/9400717 to your computer and use it in GitHub Desktop.
Sass Element and Modifier Mixins
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Mixins for element and modifier | |
//elements get appended with "__" and the $name | |
@mixin e($name) { | |
@at-root &__#{$name} { | |
@content; | |
} | |
} | |
//modifiers get appended with "--" and the $name | |
@mixin m($name) { | |
@at-root &--#{$name} { | |
@content; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment