The chunked-file-reader comes with the functionality of reading a file in chunks, so we can simplify the file example a lot by offloading this logic to that package. I think this will make it much more approachable for people wanting to reuse that code.
The chunked-file-reader package uses readAsArrayBuffer(), and we cannot use it for tests that use readAsBinaryString().
Also, chunked-file-reader always uses File.prototype.slice, but I think that's ok now, since blob.mozSlice() is only needed for Firefox 12 and earlier, though I don't on which version did Safari start supporting File.prototype.slice (I tested that it works on Safari 11 which is the current latest version).
The chunked-file-reader comes with the functionality of reading a file in chunks, so we can simplify the file example a lot by offloading this logic to that package. I think this will make it much more approachable for people wanting to reuse that code.
The chunked-file-reader package uses
readAsArrayBuffer()
, and we cannot use it for tests that usereadAsBinaryString()
.Also, chunked-file-reader always uses
File.prototype.slice
, but I think that's ok now, sinceblob.mozSlice()
is only needed for Firefox 12 and earlier, though I don't on which version did Safari start supportingFile.prototype.slice
(I tested that it works on Safari 11 which is the current latest version).Closes https://github.com/satazor/js-spark-md5/issues/48