Skip to content

Conversation

@dduponchel
Copy link
Contributor

This pull request adds several things:

On features,

  • Blob and Promise support in loadAsync() and file()
  • support and tests for JSZip.external
  • support for async("array")

On

  • enforcing rules in JSHint
  • some documentation fixes
  • upgrade some dependencies
  • improve an error message

This should cover the remaining bullet points of #224.

The methods `.file(name, data)` and `.loadAsync(data)` now accept Blob
and promises of supported types (string, Uint8Array, etc).
Now, users can override the `JSZip.external.Promise` object and use
their own.
A zip file is designed to be read backward so a stream is not suited
for this task. We could read the whole stream in memory but that would
be very counter-intuitive. The previous message is too generic ("The
data of [...] is in an unsupported format") and a better message will
save hours of debugging.
JSHint wasn't configured correctly. This commit adds enforcing rules
and apply them on production files, test files and documentation files.
Also fix offending lines.
- es6-promise is kept in 3.0 until
  stefanpenner/es6-promise#177 is released
- grunt-contrib-connect is kept in 1.0.0 until
  gruntjs/grunt-contrib-connect#213 is resolved
It almost worked, we just needed a concat fix.
@dduponchel dduponchel merged commit cb28f5e into Stuk:jszip_v3 Apr 11, 2016
@dduponchel dduponchel deleted the blob branch April 11, 2016 19:25
@dduponchel dduponchel mentioned this pull request Apr 12, 2016
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