Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Generated by SassMeister.com.
// ----
// Sass (v3.4.4)
// Compass (v1.0.1)
// ----
@mixin classStartWith($classStarters...) {
$selectors: null;
@each $classStart in $classStarters {
$selectors: $selectors, unquote("[class^=\"#{$classStart}\"], [class*=\" #{$classStart}\"]");
}
#{$selectors} {
@content;
}
}
@include classStartWith(covernode,listnode){
@at-root .anotherselector, & {
example: rule;
}
@at-root &, .anotherselector {
example: rule;
}
}
.anotherselector, [class^="covernode"], [class*=" covernode"], [class^="listnode"], [class*=" listnode"] {
example: rule;
}
[class^="covernode"], .anotherselector, [class*=" covernode"], [class^="listnode"], [class*=" listnode"] {
example: rule;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.