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

[BUGFIX beta] Migrate autorun microtask queue to Promise.then #17618

Merged
merged 1 commit into from
Feb 20, 2019

Conversation

rwjblue
Copy link
Member

@rwjblue rwjblue commented Feb 14, 2019

The primary change in backburner.js@2.5.0 is to use the Promise microtask queue primarily and falling back to MutationObserver when Promise is not present.

The test changes here are to migrate from window.onerror to window.onunhandledrejection hooks (due to moving the microtask delivery from MutationObserver to native Promise). The cross platform support for onunhandledrejection is a tad spotty (Chrome, Edge, and soon Firefox), so I had to guard in other browsers.

The primary change in Backburner.js is to use the Promise microtask
queue primarily and falling back to MutationObserver when Promise is not
present.

The test changes here are to migrate from `window.onerror` to
`window.onunhandledrejection` hooks (due to moving the microtask
delivery from `MutationObserver` to native `Promise`). The cross
platform support for `onunhandledrejection` is a tad spotty (Chrome,
Edge, and _soon_ Firefox), so I had to guard in other browsers.
@rwjblue rwjblue changed the title [BUGFIX beta] Update Backburner.js to 2.5.0. [BUGFIX beta] Migrate autorun microtask queue to Promise.then Feb 20, 2019
@rwjblue rwjblue merged commit 2d08b86 into emberjs:master Feb 20, 2019
@rwjblue rwjblue deleted the update-backburner branch February 20, 2019 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant