Skip to content

Instantly share code, notes, and snippets.

@grachov
Created November 26, 2014 13:30
Show Gist options
  • Save grachov/2448ffe6c93167a4d952 to your computer and use it in GitHub Desktop.
Save grachov/2448ffe6c93167a4d952 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
// ----
// Sass (v3.4.7)
// Compass (v1.0.1)
// ----
.a {
$parent: &;
.b {
&__c {
color: red;
@at-root #{selector-replace(&, $parent, selector-append($parent, '.d'))} {
color: green;
}
}
}
}
.a .b__c {
color: red;
}
.a.d .b__c {
color: green;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment