Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add taskify #11

Open
dggluz opened this issue Sep 5, 2018 · 1 comment
Open

Add taskify #11

dggluz opened this issue Sep 5, 2018 · 1 comment
Labels
enhancement New feature or request

Comments

@dggluz
Copy link
Collaborator

dggluz commented Sep 5, 2018

Decription

I'm not totally sure about how should be this function be to avoid being too specific to certain API, but it would be handy to avoid having to always do:

new Task((resolve, reject) => {
    funcTooBeTaskified(resolve, opts, reject);
});
@dggluz dggluz added the enhancement New feature or request label Sep 5, 2018
@dggluz
Copy link
Collaborator Author

dggluz commented Sep 5, 2018

It should probably be another version (or make this version flexible enough to support it) for the functions that throw errors instead of passing it as parameters via CPS.

Two examples that illustrate both forms are: fs.readFile and JSON.parse.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant