在haml中,以下代码将生成正确的嵌套HTML:
%p Hi There I'm inside this paragraph
%button I'm also inside this paragraph产生:
<p> Hi There I'm inside this paragraph <button>I'm also inside this paragrpah</button></p>在Emblem.js中,如果我这样做:
p Hi There I'm inside this paragraph
%button I'm also trying to be in the paragraph它会产生这样的结果:
<p> Hi There I'm inside this paragraph %button I'm also trying to be in the paragraph</p> 有人知道如何在emblem.js中嵌套内容和元素吗?
发布于 2014-12-18 15:21:00
p Hi There I'm inside this paragraph
button I'm also trying to be in the paragraph如果没有%就行了
我可以推荐查看http://emblemjs.com/syntax/,这是一个很好的资源,它简要地解释了每一个可能的用例。
https://stackoverflow.com/questions/27539540
复制相似问题