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

Fix JavaScript parsing error in IE 10 and earlier #6396

Merged
merged 4 commits into from
Apr 9, 2018
Merged

Conversation

mramato
Copy link
Contributor

@mramato mramato commented Mar 31, 2018

While Cesium doesn't work in IE10, we need to allow the JS to parse so that an app can still function without Cesium. In this case, Uint8ClampedArray isn't supported in IE 10, so the arraySlice polyfill was throwing on load. I cleaned up arraySlice and deduplicated common TypedArray code into FeatureDetection.

To Test, load Viewer in IE11 with the debugger open and set to IE10 compatibility mode.

While Cesium doesn't work in IE10, we need to allow the JS to parse so that
an app can still function without Cesium.  In this case, Uint8ClampedArray
isn't supported in IE 10, so the arraySlice polyfill was throwing on load.
I cleaned up `arraySlide` and deduplicated rom TypedArray code into
FeatureDetection.

To Test, load Viewer in IE11 with the debugger open and set to IE10
compatibility mode.
@cesium-concierge
Copy link

Signed CLA is on file.

@mramato, thanks for the pull request! Maintainers, we have a signed CLA from @mramato, so you can review this at any time.

⚠️ I noticed that CHANGES.md has not been updated. If this change updates the public API in any way, fixes a bug, or makes any non-trivial update, please add a bullet point to CHANGES.md and comment on this pull request so we know it was updated. For more info, see the Pull Request Guidelines.


I am a bot who helps you make Cesium awesome! Contributions to my configuration are welcome.

🌍 🌎 🌏

return copy;
};
var copy = Array.prototype.slice.call(array, begin, end);
var typedArrayTypes = FeatureDetection.typedarrayTypes;
Copy link
Contributor

Choose a reason for hiding this comment

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

typearrayTypes -> typedArrayTypes?

@hpinkos
Copy link
Contributor

hpinkos commented Apr 2, 2018

That's it, this change looks fine

@mramato
Copy link
Contributor Author

mramato commented Apr 9, 2018

Thanks, should be ready.

@hpinkos
Copy link
Contributor

hpinkos commented Apr 9, 2018

👍

@hpinkos hpinkos merged commit 8e7f485 into master Apr 9, 2018
@hpinkos hpinkos deleted the ie-loading branch April 9, 2018 19:32
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.

3 participants