You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all: I really like the way you wrote this bridge - I was on my way of writing the same thing on my own so this is seriously cool to see. :)
I see that your code depends on bluebird - which is quite heavy when compared to native promises. It has the upshot of being available anywhere, but perhaps you'd consider moving to native promises with some polyfill like any-promise and add bluebird as optional dependency?
A pull request that could demo how to improve this issue will be welcome. Please feel free to submit solutions so that we could be able to start a discussion based on that.
Hey. I tried a little but I'd need to dig in a bit more to make this work - the issue is in the use of two Bluebird methods try and finally (the latter is available in node v10). I don't want to add any polyfills as a dependency so I'll need to drill deeper into the issue...
@MichalCz I was able to remove bluebird in #28—which yea removes removes/changes some functionally (especially the .catch(...) semantics). I'm ok with that since I personally use async/await, and then the default behavior will be the built in Promise, which makes sense, because then people can wrap it with bluebird or whatever if they choose to.
The remaining work is to
update the readme to reflect the changes (some of the examples will no longer work)
and since they have to be updated I think it make sense to show async/await now!
make sure all the readme examples are defined as tests
make sure all the tests pass!
I'm about to sign off for tonight, but any help would be greatly appreciated :D
Activity
JYone3A commentedon Apr 9, 2019
+1
munro commentedon Apr 10, 2019
@mickdekkers yessss that would be awesome!
huan commentedon Apr 10, 2019
Thanks for the suggestion!
A pull request that could demo how to improve this issue will be welcome. Please feel free to submit solutions so that we could be able to start a discussion based on that.
MichalCz commentedon Apr 18, 2019
Hey. I tried a little but I'd need to dig in a bit more to make this work - the issue is in the use of two Bluebird methods
tryandfinally(the latter is available in node v10). I don't want to add any polyfills as a dependency so I'll need to drill deeper into the issue......and I don't know when I'd find some time...
[fixes #27] remove bluebird
munro commentedon Apr 24, 2019
@MichalCz I was able to remove bluebird in #28—which yea removes removes/changes some functionally (especially the
.catch(...)semantics). I'm ok with that since I personally use async/await, and then the default behavior will be the built inPromise, which makes sense, because then people can wrap it with bluebird or whatever if they choose to.The remaining work is to
I'm about to sign off for tonight, but any help would be greatly appreciated :D
MichalCz commentedon Apr 24, 2019
@munro I'll check that out. :)
munro commentedon Feb 5, 2021
Just got some expert insight on how to better handle this transition 🎉