是否可以在 underscore.js 或 lodash 中添加非 html 注释?
类似于:
<%-- We do this here because... %>
这样注释就不会出现在生成的 html 代码中吗?
如果我写:
<!-- We do this here because... -->
评论位于生成的 html 中。
谢谢。
最佳答案
这是一个客户端模板,您仍然会看到评论,但不会重复等...
<%
// comments go here
%>
关于javascript - 是否可以在 underscore.js 或 lodash 模板中添加非 html 注释?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15023513/