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

WV-2398: Fix iOS browser crashes #3997

Merged
merged 1 commit into from
Oct 5, 2022
Merged

WV-2398: Fix iOS browser crashes #3997

merged 1 commit into from
Oct 5, 2022

Conversation

jasontk19
Copy link
Collaborator

Description

Changes were introduced in OL 6.14.2 that causes browsers to crash on iOS for us after reaching a certain number of layers rendered. See openlayers/openlayers#14171

The inclusion of the className property when creating layers on our end prevents canvas re-use between layers which causes a large performance hit, leading to the crash on iOS devices. Removing className fixes the issue.

How To Test

  • Pull changes
  • npm ci
  • Open the app on an actual iOS device
  • Load any fire event (this will add many layers)
  • Confirm the app does not crash

You will need to find a way to hit your local dev server from an iOS device, such as using a reverse proxy like ngrok. This error did not seem to happen in simulated devices and definitely won't occur in a desktop browser set to mobile size.

- Use latest versi of OL
- Remove className attr which causes perf hit
@jasontk19 jasontk19 added this to the v3.34.0 milestone Oct 5, 2022
@jasontk19 jasontk19 self-assigned this Oct 5, 2022
@jasontk19 jasontk19 marked this pull request as ready for review October 5, 2022 14:47
Copy link
Collaborator

@ryanweiler92 ryanweiler92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was able to verify that this works on my personal iOS mobile device going through ngrok.

@jasontk19 jasontk19 merged commit 36c8870 into develop Oct 5, 2022
@jasontk19 jasontk19 deleted the wv-2398 branch October 5, 2022 17:09
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.

2 participants