带斜杠的Sass内容

带斜杠的Sass内容,sass,Sass,我在尽量减少我的无礼,而角色引用把我搞砸了 @each $name, $color, $code in ("info" "#286fad" "\e88f", "error" "#ad2828" "\e001") { .#{$name}-banner { background-color: $color; &:before { content: '#{$code}'; } } } 我得到的是: 内容:

我在尽量减少我的无礼,而角色引用把我搞砸了

@each $name, $color, $code in ("info" "#286fad" "\e88f", "error" "#ad2828" "\e001") {
    .#{$name}-banner {
        background-color: $color;
        &:before {
            content: '#{$code}';
        }
    }
}
我得到的是:

内容:";
我所期望的是:

内容:“\e88f”;

一直在使用字符串插值,直到我找到了一些可以解决这个问题的方法。有点痛苦,但现在开始吧

@每个$name、$color、$code输入(信息#286fad e88f,错误#ad2828 e001){
.#{$name}-横幅{
背景色:$color;
&:之前{
内容:#{'\\'+$code+''''''};
}
}

}
谢谢!昨天刚开始使用sass。