代码拉取完成,页面将自动刷新
javascript-based template engine:
1) runtime in client-side, reduce computing render in server-side;
2) language-independent, not-bound with backend scripts/languages;
3) totally-isolated between MVC, data transfer with JSON;
4) full-support with built-in logic and customerized functions, express powerfully;
JavaScript规范中,变量命名只允许 a-zA-Z 和 _, $ 开头;
http://krasimirtsonev.com/blog/article/Javascript-template-engine-in-just-20-line
https://developer.mozilla.org/en-US/docs/Web/JavaScript/A_re-introduction_to_JavaScript
steps:
0. html tpl file (xxx.html) with javascripts enclosed with tags {} (changeable?);
1. reverse all html into strings;
2. parse all javascripts;
3. read json serialized data from an html element;
4. merge with javascripts and output;
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。