摘要: 通过 queueMicrotask() 使用微任务 阅读全文
posted @ 2021-02-01 12:11 LiuWango 阅读(1878) 评论(0) 推荐(0) 编辑
摘要: // JS主任务(宏任务1)开始,输出1.Start console.log('1.Start') // setTimeout为宏任务(2),加入宏任务事件循环 setTimeout(function() { console.log('2.Timer is on'); }); new Promise 阅读全文
posted @ 2021-02-01 01:07 LiuWango 阅读(230) 评论(0) 推荐(0) 编辑