my-promise-ts-imple
v1.0.5
Published
一个基于ts实现的Promise
Downloads
7
Readme
一个基于 ts 实现的 Promise
下载
npm install my-promise-ts-imple
使用方法
import MyPromise from "my-promise-ts-imple";
new MyPromise()
.then(
(val) => {
// TODO OnFulfiilled Impl
},
(reason) => {
// TODO OnRejected Imple
}
)
.catch((err) => {
// TODO handle Error
})
.finally(() => {
// TODO handle Finally
});