Core-js: unhandledrejectionhandler called multiple times for same error

Created on 14 Jul 2017  路  3Comments  路  Source: zloirock/core-js

When chaining promises using then the behavior between Chrome's native onunhandledrejectionhandler and core-js' implementation differ.

Promise.reject(43).then(x => x); will invoke the handler twice in core-js and once in Chrome.
I suppose Chrome's behavior is correct.

demo

bug

Most helpful comment

Fixed in [email protected].

All 3 comments

In this example, we have 2 promises, so triggered 2 events. Need to check HTML spec for confirming which behaviour is correct.

@zloirock the ES spec is ambiguous about this

Fixed in [email protected].

Was this page helpful?
0 / 5 - 0 ratings