我使用Prepros编译* .jade模板。
当前的翡翠代码:
pre
code.hljs
.ui-button {
@include button;
&.xs {@include button-size(xs);}
&.sm {@include button-size(sm);}
&.md {@include button-size(md);}
&.lg {@include button-size(lg);}
&.xl {@include button-size(xl);}
&.xxl {@include button-size(xxl);}
}
预期结果:
<pre>
<code class="hljs">
.ui-button {
@include button;
&.xs {@include button-size(xs);}
&.sm {@include button-size(sm);}
&.md {@include button-size(md);}
&.lg {@include button-size(lg);}
&.xl {@include button-size(xl);}
&.xxl {@include button-size(xxl);}
}
</code>
</pre>
答案 0 :(得分:0)
<强>答案:强>
CSS代码不需要代码转义。
pre
code.hljs
| .ui-button {
| @include button;
| &.xs {@include button-size(xs);}
| &.sm {@include button-size(sm);}
| &.md {@include button-size(md);}
| &.lg {@include button-size(lg);}
| &.xl {@include button-size(xl);}
| &.xxl {@include button-size(xxl);}
| }