Allow progress info while downloading
GuillaumeLeclerc opened this issue · 4 comments
GuillaumeLeclerc commented
The XHR object allow you to know the progess of the download. It might be a good thing to be able to access it using this.
ufukomer commented
Is not there any solution for this yet?
Stuk commented
Just a bit of a delay. I've reviewed the PR.
Stuk commented
Released as version v0.1.0.
Pass an options object with a progress
callback:
JSZipUtils.getBinaryContent("ref/amount.txt", {
progress: function(e) {
console.log(e.percent + "% loaded");
},
callback: function (err, data) {
// ...
}
});