Created
June 18, 2014 01:16
-
-
Save heyMP/dd7134762fc38d0c3211 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
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
// ---- | |
// Sass (v3.3.4) | |
// Compass (v1.0.0.alpha.18) | |
// ---- | |
@function splitString($string, $var, $location: 'first') | |
{ | |
$length : str-length($string); | |
$index : str-index($string,$var); | |
$first : str-slice($string,0,$index - 1); | |
$second : str-slice($string,$index + 2,$length); | |
@if $location == 'first' { | |
@return $first; | |
} @else { | |
@return $second; | |
} | |
} | |
.node-article { | |
$block: '.node-article'; | |
&__element { | |
$element: 'element'; | |
content: 'test'; | |
@at-root #{}#{$block} { | |
content: 'testing'; | |
} | |
} | |
} | |
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
Invalid CSS after " @at-root #{": expected expression (e.g. 1px, bold), was "}#{$block} {" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment