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

4.1.0 chunk load error on iOS Safari #540

Open
pavch opened this issue Jun 28, 2022 · 4 comments
Open

4.1.0 chunk load error on iOS Safari #540

pavch opened this issue Jun 28, 2022 · 4 comments
Assignees

Comments

@pavch
Copy link

pavch commented Jun 28, 2022

Basic information

MapillaryJS version: 4.1.0
System/Browser: Safari Mobile

Steps to Reproduce Behavior

  1. Install mapillary-js package 4.1.0 to project with angular version 11.2.14.
  2. Create production build and run the app on iOS Safari.
  3. We are observing the following error:
    ERROR ERROR Error: Uncaught (in promise): ChunkLoadError: Loading chunk 4 failed.
    The error is reproducable with clean cache on Safari. Removing mapillary and readding it with version 4.0.0 is fixing the issue. Readding mapillary-js 4.1.0 is showing the same error again, so our team is assuming this is not related to the common chunk errors, caused by wrongly cached files.
    Could you help us identify what in mapillary can cause such behaviour?

Thank you!

@oscarlorentzon
Copy link
Member

The MapillaryJS version 4.1.0 bundle works standalone on iOS.

I am unfamiliar with Angular. How does the Angular production build affect the inner code structure of dependencies?

@sandromartis
Copy link

Some three.js versions seems to cause issues in Safari:
angular/angular-cli#21107
https://stackoverflow.com/questions/68224800/left-hand-side-of-operator-must-be-a-reference-only-in-webkit-safari-in-ang

Maybe this is related?

@pavch
Copy link
Author

pavch commented Sep 30, 2022

yes, buildOptimizer=false is fixing the issue for angular versions below 12 as mentioned in the link

@oscarlorentzon
Copy link
Member

@sandromartis @pavch Thanks for providing additional information and workaround. For the next MJS version we will ensure that three.js is upgraded to the latest version. Hopefully the Angular build optimization can be used again then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants