Skip to content

hemanth/promise-to-task

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

promise-to-task Build Status

Tiny module to convert a Promise into Task.

Install

$ npm install --save promise-to-task

Usage

const promiseToTask = require('promise-to-task');
const promise = new Promise((res, rej) => {}))

promiseToTask(promise)
.rejectedMap(e => 'oops')
.fork(console.warn, console.log);

API

promiseToTask(input)

input

Type: Promise

The Promise that you need to convert to a Task.

License

MIT © Hemanth.HM

About

Tiny module to convert a Promise into Task.

Resources

License

Stars

Watchers

Forks

Packages

No packages published