我用Jade 1.3.0在Laravel上。我定义了这个混合器:
mixin ShotPreview()
div(attributes).shot-preview.tile
each n in [1,2,3]
div.tile-content
img(src="/thumbs/{{shot.id}}_#{n}.jpg")
if(block)
block我把它叫做
+ShotPreview()(data-role="live-tile" data-effect="fade" ng-class="{'selected': shot.selected}" ng-click="shot.selected=!shot.selected").live.double但是,我的复合元素的根div元素被呈现为
<div attributes="attributes" class="shot-preview tile">我也不知道为什么。没有错误,语法在我看来也不错。我刚认识杰德,所以我想这是件很愚蠢的事,但我真的被困住了。
发布于 2014-04-07 12:33:12
您需要使用新的语法,将属性传递给元素。
div&attributes(attributes).shot-preview.tilehttps://stackoverflow.com/questions/22836406
复制相似问题