【发布时间】:2015-05-08 00:03:07
【问题描述】:
我试过这个包https://github.com/matteodem/meteor-easy-search/使用这个示例代码轻松搜索
<template name="searchBox">
{{> esInput index="players" placeholder="Search..." }}
<ul>
{{#esEach index="players"}}
<li>Name of the player: {{name}}</li>
{{/esEach}}
</ul>
</template>
并将其转换为玉
template(name="searchBox")
+esInput index="players" placeholder="Search..."
ul
esEach index="players"
li Name of the player: {{name}}
如果我使用 html 格式,则搜索有效,但当我使用翡翠格式时,没有错误,但搜索不会显示。我是否正确地将html转换为玉?任何想法为什么翡翠不起作用?
【问题讨论】:
-
我没在 Meteor 中使用过翡翠,但
esEach不应该是+esEach吗?我猜esEach被解释为一个元素。 -
@PeppeL-G 好收获!您能否将其作为答案,以便我接受。谢谢!
标签: javascript html node.js meteor pug