-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
How can I use jszip with Expo (React Native) ? #521
Comments
I am getting this too:
I don't think it's related to a specific ui/js framework, as I am using angular6/devextreme while getting this error. I expect it to be a problem with webpack 4 bundling maybe, as the error occures after upgrading from angular5 to angular6 which is using webpack 4. |
Yes, having the same issue when building for angular6. I think the issue is due to package.json main is pointing to |
@beeing |
Has anyone figured out how to use jszip with react-native? |
I fixed this error by installing the unresolved module. So |
When webpack/rollup or another bundler, implementing the [`browser-resolve`](https://www.npmjs.com/package/browser-resolve) spec tries to resolve `jszip` for a browser-based project they fail with: ``` ERROR in ./node_modules/jszip/lib/readable-stream-browser.js Module not found: Error: Can't resolve 'stream' in '/node_modules/jszip/lib' ``` Since you already produce a browser build, we just need to point to it inside of `package.json`'s `browser` field. PS: You'd probably want to double check the semantics of `"."`. Looking at `browser-resolve` it seems that everything will work as expected. Also, trying empirically with webpack, everything worked out, but few more pairs of eyes would be greatly appreciated. Also @sokra should be able to share a valuable opinion. Fix Stuk#524 Fix Stuk#521 Fix Stuk#477
I get "unable to resolve module 'stream' when I try to use jszip in an Expo app.Expo is a javascript only version of React Native.
The text was updated successfully, but these errors were encountered: