Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Sample format for the new Silent Feature for Sass
// Scss @extend as of now
.small {
font-size: 0.9em;
}
footer,
article > footer {
@extend .small;
background-color: red;
}
----
// Generated CSS
.small,
footer,
article > footer {
font-size: 0.9em;
}
footer,
article > footer {
background-color: red;
}
-----------------------
// Proposed Solution for Silent
@extendtemplate small {
font-size: 0.9em;
}
footer,
article > footer {
@extend small; // @extend can take a selector or an extend template
background-color: red;
}
----------------------
// Proposed Solution Compiled into CSS
footer,
article > footer {
font-size: 0.9em;
}
footer,
article > footer {
background-color: red;
}
@seutje

This comment has been minimized.

Copy link

seutje commented Jan 4, 2012

this would be rather awesome, as I often find myself giving my extendables funky names to avoid accidental extending, which I've had occur more than once :(

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.