Skip to content
This repository has been archived by the owner on Sep 20, 2019. It is now read-only.

regression: Promise.prototype.catch is undefined in IE11 (v1.0.8+) #837

Closed
vlukashov opened this issue Sep 3, 2017 · 1 comment
Closed
Assignees

Comments

@vlukashov
Copy link
Contributor

Starting from the version 1.0.8 of the WebComponents polyfill, the ES6 promise polyfill shipped as a part of webcomponents-lite.js does not define the Promise.prototype.catch method. For example, the app-storage web components break the app in IE11 starting with WebComponents polyfill 1.0.8 (1.0.7 is still OK).

Here is a demo app (broken in IE11): https://github.com/vlukashov/polymer-local-storage.

Most likely, the root cause is closure-compiler/#2640, but for some reason the issue did not surface with the polyfill versions 1.0.7 and before.

Workaround
Pin the version of the WebComponents polyfill to 1.0.7 or less.

@ChadKillingsworth
Copy link

@azakus Looks like you probably need to manually assign the es6-promise Promise object to window.Promise rather than depend on the auto registration.

Alternatively, just remove the rewrite_polyfills=false flag for this case and use the Compiler provided promise polyfill.

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

No branches or pull requests

3 participants