摘要: 1 class Promise { 2 constructor (executor) { 3 // 控制异步执行的状态 4 this.pending = "pending" 5 // 用来保存异步执行的结果 6 this.data = undefined 7 // 使用箭头函数 让this指向 当前 阅读全文
posted @ 2021-09-18 00:43 一个动态类型的幽灵 阅读(66) 评论(0) 推荐(0) 编辑