这可以编译,但如果我在最后删除div
,它会引发错误。我正在使用 codekit 进行编译。我没有得到什么?为什么这很div
重要?
mixin ListItemDetail(labels,values)
.listItemSection
.listItemDetailWrap
.listItemDetail #{labels[0]} :
.listItemDetail #{values[0]}
.listItemDetailWrap
.listItemDetail #{labels[1]} :
.listItemDetail #{values[1]}
.listItemDetailWrap
.listItemDetail #{labels[2]} :
.listItemDetail #{values[2]}
mixin ListItem()
.listItem
.listItemSection
h2 48 barrels of Kansas Common by 00/00/0000
small Ellsworth County, Kasas, 38.4500° N 96.5333° W
mixin ListItemDetail(['Start Date', 'End Date', 'Pickup Deadline'], ['00/00/0000', '00/00/0000', '00/00/0000'])
mixin ListItemDetail(["Bulletin", "Grade", "Join Deadline"], ["Plains", "Light Crude", "00/00/0000"])
mixin ListItemDetail(["API", "BS&W", "Sulfur"], ["48°", "4%", "0.1%"])
div
如果缺少最后一个,这是代码包日志中发生的错误div
:
/Applications/CodeKit.app/Contents/Resources/engines/jade/lib/runtime.js:173
throw err;
^
Error: /Users/isaac/Radiant/DemandPoint/dpe-grails/web-app/jade/Elements/ListItem.jade:23
21| mixin ListItemDetail(["API", "BS&W", "Sulfur"], ["48°", "4%", "0.1%"])
22|
> 23|