promissive
v1.0.1
Published
A very lightweight and naive callback-to-promise function converter.
Downloads
11
Maintainers
Readme
promissive
call your cb-based func in promissive manner
usage
request.promise(options).then((res) => {
//your logic here
});
is equiv-to:
return new Promise((resolve, reject) => {
request(options, (err, res) => {
return resolve(res);
});
});