 叫我小J
 叫我小J Promise 的核心其实就在于几点:
创建实例 romise:
var p = new Promise(executor)
promise 的状态变化时,触发 then/catch 注册的回调函数:
p.then(onFulfilled, onRejected)
p.catch(onRejected)
函数运行时的异常处理:
try{ .. } catch(err){ onRejected(err) }
回调函数的异步执行
结合 promise 机制图
基于 
new Promise((resolve, reject) => {}).then(onFulfilled, onRejected).catch(onRejected)编写 Promise 其它方法。
.prototype.finally().resolve().reject().all().allSettled().any().race()基于手写 Promise polyfill 我们要知道些什么呢?
没想到吧,promise 流程的控制竟然如此简单