How to modify the root parent selector in sass -
this question has answer here:
how can modify root element of parent selector chain? (using sass 3.3.x) like...
=prepend($prefix) @at-root .#{$prefix}#{&} // note there no dot (.) separating @content .foo .bar +prepend(baz) background: red and return
.baz.foo .bar { background: red; } or better... explicit way target root element (or nth element)?
=prepend($prefix) &.#{$prefix} @content .foo +prepend("baz") .bar background: red returns this:
.foo.baz .bar { background: red; } on right track?
Comments
Post a Comment