-
Notifications
You must be signed in to change notification settings - Fork 67
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
Unhandled rejection detection #20
Comments
I have some very mixed feelings on this, on one hand it's an extremely useful feature on the other in's a non standard api so so this would no longer be a drop in replacement for native promises which can cause problems (see pouchdb/pouchdb#3839) |
@calvinmetcalf it is a standard API in that everyone implements it, in fact native promises already do it in io.js and NodeJS accepted it but since the merger was declared they're just waiting for io.js to merge with node over the io.js codebase. This is mostly useful in order to be compatible with native promises. nodejs/node#256 Documented here: https://iojs.org/api/process.html#process_event_unhandledrejection btw Note that this mostly affects server-side usage. |
yeah it's browserify usage I'm thinking of that could be affected |
Hmm how so? The code checks if You can see how I implemented this in Q here: kriskowal/q@1c38507 |
if somebody does something like |
@calvinmetcalf if someone does These events already happen on the serverside in which case if a library is using
|
let me look into how I can impliment it to work server side without increasing the client side code footprint unnecessarily |
I was going to point out you can use a tool like envify and then use the fact minifiers strip dead code but it seems like you've figured something out already :) Thanks. |
Yeah the env seemed like a bit of a hack plus down stream packages could have used conflicting env stuff |
Yes, the approach you took does sound better. Let me know if you need any help pushing this forward and thanks for doing this :) |
done in 2.9.0 |
Awesome, thanks a ton! On Wed, May 27, 2015 at 2:53 PM, Calvin Metcalf [email protected]
|
If you'd like, implementing this API would be really awesome, Bluebird When and native promises on the server do this:
https://gist.github.com/benjamingr/0237932cee84712951a2
Cheers
The text was updated successfully, but these errors were encountered: