utils.delay: use macro tasks instead of micro tasks. #288

Merged
merged 2 commits into from Jul 25, 2016

Projects

None yet

1 participant

@dduponchel
Collaborator

As says the documentation of asap,

ASAP strives to schedule events to occur before yielding for IO,
reflow, or redrawing.

The goal of async methods in JSZip is to not freeze the browser, a macro task
is a better choice here. See
https://github.com/YuzuJS/setImmediate#macrotasks-and-microtasks for a
description of micro/macro tasks.

Fix #280.

dduponchel added some commits Apr 26, 2016
@dduponchel dduponchel utils.delay: use macro tasks instead of micro tasks.
As says the documentation of [asap](https://github.com/kriskowal/asap),

> ASAP strives to schedule events to occur before yielding for IO,
> reflow, or redrawing.

The goal of async methods in JSZip is to not freeze the browser, a macro task
is a better choice here. See
https://github.com/YuzuJS/setImmediate#macrotasks-and-microtasks for a
description of micro/macro tasks.

Fix #280.
06c8c62
@dduponchel dduponchel Fix stream test and improve test readability.
The stream test was too fragile and randomly broke on some devices.
While trying to debug it, I also improved the reporting of errors in
saucelabs.
4931501
@dduponchel
Collaborator

@CVex2150J could you confirm that this pull request fixes your issue ? I rebuilt the dist/ files on my (temporary) branch fix_280_dist if you need them.

@dduponchel dduponchel merged commit c8b8d2b into Stuk:master Jul 25, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@dduponchel dduponchel deleted the dduponchel:fix_280 branch Jul 25, 2016
@dduponchel dduponchel referenced this pull request Aug 2, 2016
Merged

Release v3.1.0 #326

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment