-
-
Save vishaltelangre/5177337 to your computer and use it in GitHub Desktop.
Setting selector name dynamically in SASS
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
@mixin active($selector) { | |
#{$selector} { | |
color:black; | |
} | |
} | |
#my-id { | |
@include active($selector: ".my-class") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment