Skip to content

Errors in IE11 when importing polyfills using es-abstract. #5615

Open

Description

@JustinTRoss

Is this a bug report?

Yes

If you import react-app-polyfill/ie11 before importing any shim/polyfill using es-abstract lib, you get an error in IE11 (possibly other browsers as well). Some example polyfills: object.entries, array-includes, object.values

Error: object doesn't support property or method Symbol(Symbol.iterator).9_<some-hash>
Location: es-abstract -> GetIntrinsic.js at line 56.
Workaround: import react-app-polyfill/ie11 after importing all shims/polyfills using es-abstract.

Environment

IE11, presumably anything IE.

Steps to Reproduce

  1. Create new app
  2. in index.js, on line 1, import react-app-polyfill/ie11
  3. in index.js, on line 2, import objectValues from 'object.values/polyfill'
  4. Open your app in IE11.

Expected Behavior

App would run.

Actual Behavior

App crashes.

Activity

  1. JustinTRoss commented on Oct 29, 2018

    @JustinTRoss
    Author

    The equivalent was filed with es-abstract: ljharb/es-abstract#39 .

  2. ljharb commented on Oct 29, 2018

    @ljharb

    Seems like this might be the Symbol sham (since symbols can’t be fully polyfilled). If that’s the case, i can probably work around this in es-abstract, but a better solution would be not polyfilling Symbols at all.

  3. Timer commented on Oct 29, 2018

    @Timer
    Contributor

    I wonder if core-js v3 behaves differently. Maybe try this: zloirock/core-js#419 (comment)?

    x-ref zloirock/core-js#262

  4. stale commented on Nov 28, 2018

    @stale

    This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs.

  5. ljharb commented on Nov 28, 2018

    @ljharb

    bump

  6. thecristen commented on Dec 3, 2018

    @thecristen

    I also have this issue thanks to react-app-polyfill/ie11's Symbol polyfill making my app not work in IE 11.

  7. ChristianOlsson commented on Dec 17, 2018

    @ChristianOlsson

    I am seeing the same issue. I have started using @babel/polyfill instead as a workaround.

  8. Timer commented on Dec 23, 2018

    @Timer
    Contributor

    Not sure of the best path forward here.

  9. ljharb commented on Dec 23, 2018

    @ljharb

    I’ve been unable to reproduce this without CRA; see ljharb/es-abstract#39 (comment) - consistent repro steps with es-abstract and core-js in isolation should make it trivial to address.

  10. added this to the 2.1.3 milestone on Dec 24, 2018
  11. modified the milestones: 2.1.3, 2.1.4 on Jan 4, 2019
  12. modified the milestones: 2.1.4, 2.1.5 on Feb 10, 2019
  13. devuxer commented on Mar 3, 2019

    @devuxer

    I'm having a similar issue, except in my case, it's some weirdness involving getOwnPropertyDescriptor.

  14. modified the milestones: 2.1.6, 2.1.x, 3.x on Mar 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions