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

JSZip is not a constructor #778

Closed
igandrews opened this issue Nov 7, 2018 · 1 comment
Closed

JSZip is not a constructor #778

igandrews opened this issue Nov 7, 2018 · 1 comment

Comments

@igandrews
Copy link

I'm seeing an error in the console ('JSZip is not a constructor') when trying to create an instance of JSZip in stackblitz. You can see a simple example here.

It doesn't seem to matter how I import it. We use the following in our code.
import * as JSZip from 'jszip/dist/jszip';
But I also tried including the @types/jszip and using the following but the result is the same.
import * as JSZip from 'jszip';

If however I change it from new JSZip() to new JSZip.default() then it works but that wasn't necessary previously and doesn't seem like it should now either since locally the project does work.

@purplem1lk
Copy link
Contributor

Thank you for your patience - I don't see the initial error that you mentioned, but it's possible that code changes since the inception of this issue have solved the error you were seeing. If this issue persists, feel free to tag me or ask to reopen this issue with screenshots of the error. Thank you! :)

Screen Shot 2021-04-30 at 4 55 25 PM

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

No branches or pull requests

2 participants