meteor-async-template-helpers:在模板助手中使用异步函数

时间:2021-06-17 00:42:29
【文件属性】:
文件名称:meteor-async-template-helpers:在模板助手中使用异步函数
文件大小:2KB
文件格式:ZIP
更新时间:2021-06-17 00:42:29
JavaScript 流星异步模板助手 在模板助手中使用异步函数 安装 使用 Meteor 安装: $ meteor add hpx7:async-template-helpers 用法 RegisterAsyncHelper ( options , fn ) options.template :要在其上注册助手的模板。 options.helperName : 辅助函数的名称 options.shared :一个布尔值,控制是否应该为options.template每个实例创建自动运行或只创建一次。 fn :异步助手。 这个函数将被React性地调用,它会接收一个回调作为传递它的值的参数。 例子 RegisterAsyncHelper ( { template : Template . search , helperName : 'searchResults' , shared : true }
【文件预览】:
meteor-async-template-helpers-master
----async-template-helpers.js(413B)
----package.js(490B)
----.gitignore(10B)
----README.md(1KB)

网友评论