会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
Ajanuw
做自己的King
博客园
首页
管理
2020年4月11日
js generator和yield
摘要: function co<T>(fn: () => Generator<any, any, any>): Promise<T> { const g: Generator = fn(); return new Promise((resolve, reject) => { const r = g.next
阅读全文
posted @ 2020-04-11 10:17 Ajanuw
阅读(175)
评论(0)
推荐(0)