流星预期 "div" 结束标签 - 是否有可能绕过这个?



我试图将div的开头放在"页眉"模板中,结尾放在"页脚"模板中。不幸的是,流星在建造过程中出现以下情况,未能启动:

Your app is crashing. Here's the latest log.
=> Meteor server restarted
Errors prevented startup:
While building the application:
file.html:22: Expected "div" end tag

实现从一个模板开始到另一个模板结束的div的正确方法是什么?

提前谢谢。

根据需要扩展模板。

如果没有你的代码示例,我只能假设你想做什么。

<body>
   <div class="container">
      <div id="another-div">
         {{> header}}
      </div>
      {{> footer}}
   </div>
</body>
<template name="header">
   <nav id="header">
      <!-- content -->
   </nav>
</template>
<template name="footer">
   <footer id="footer">
      <!-- content -->
   </footer>
</template>

话虽如此,你的文章中的代码示例将有助于指定答案。

相关内容

最新更新