Closed landy2014 closed 9 years ago
具体的我描述不是很好描述,上图吧。 我使用的是art-template的原生语法来写模板的。 这是编译前的模板文件 header.html:
这是编译后的模板文件:template.js define(function(require) { return require("./template")("header", function($data) { "use strict"; var $utils = this, $escape = ($utils.$helpers, $utils.$escape), name = $data.name, $out = ""; return $out += " ", $out += $escape(name), $out += " ", new String($out); }); });
下面是我在index.html页面上使用seajs调用:
运行后浏览器console显示如下:
li标签里面的数据显示不出来了。 今天才刚开始使用tmodjs,不是很明白为什么,希望能得到解答,谢谢。
贴了些html代码,被转换了。我截图吧,不好意思。
具体的我描述不是很好描述,上图吧。 我使用的是art-template的原生语法来写模板的。 这是编译前的模板文件 header.html:
这是编译后的模板文件:template.js define(function(require) { return require("./template")("header", function($data) { "use strict"; var $utils = this, $escape = ($utils.$helpers, $utils.$escape), name = $data.name, $out = ""; return $out += " - ", $out += $escape(name), $out += "
",
new String($out);
});
});
下面是我在index.html页面上使用seajs调用:
运行后浏览器console显示如下:
li标签里面的数据显示不出来了。 今天才刚开始使用tmodjs,不是很明白为什么,希望能得到解答,谢谢。