防止脚本模板的Jade插值

我正在使用node.js和express.js呈现一个index.jade页面,其中包含几个脚本块,其中包含要通过主干和下划线使用的模板。 我面临的问题是,由于在模板中包含<%=%>样式variables,所以Jade渲染失败。 下面的代码片段导致语法错误:

script#tpl-things-list-item(type='text/template') td a(href=<%= _id %>) link text td <%= name %> td <%= age %> 

请注意,这只是一个问题,当我在href值内使用一个variables,如果我删除整个href,这个片段工作得很好。 有没有办法解决这个问题? 我想继续使用Jade来定义模板,因为它非常简洁,但是这是一个显示屏。

得到它了。

 !!! 5 html(lang='en') head title= title body h1= "Hello World!" script#tpl-things-list-item(type='text/template') td a(href!="<%= _id %>") link text td <%= name %> td <%= age %>