A short mixin to insert a given character in generated content element before an element.
//include a character with before | |
@mixin insert-before($char: '-') { | |
&:before { | |
content: $char; | |
@content; | |
} | |
} | |
@mixin checkmark() { | |
@include insert-before('√') { | |
padding-right: 5px; | |
color: $base-accent-color; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment