过滤器)"/>
模板引擎 拓展方法(过滤器)
template-web.js 模板引擎 拓展方法(过滤器)
用法:
template.defaults.imports.+方法名 = function ( 参数 ) {}
template.defaults.imports.myParseInt = function (str) {if ( parseInt(str) > 0 ) {return 1;} else {return 0;}
};
使用:
<span class="num org">{{b.health_money | myParseInt}}</span>
更多推荐
模板引擎 拓展方法(过滤器)
发布评论