Skip to content

Application crashes on IE11 and lower, Syntax error #5832

@Luke93dev

Description

@Luke93dev

Is this a bug report?

Yes

Did you try recovering your dependencies?

Yes

Environment

node version: 8.11.1,
npm version: 5.6.0

This problem is specific for IE11 running on Windows 10

Steps to Reproduce

  1. npx create-react-app my-app
  2. cd my-app
  3. npm start
  4. Open application in IE11 browser

Expected Behavior

I expected my app to load, like it does in Chrome, Firefox and Safari.

Actual Behavior

Got console error - "Syntax error" after running npm start command. Debugger points to ansi-regex dependecy in node-modules, the problem is ES6 arrow function syntax. Any ideas how can I fix this? I tried using react-app-polyfill package but with no results.

image

It seems related to this old topic: #2691

ansi-regex in version 3.00 or higher exports arrow functions instead of regular functions and it causes error in IE11. Previously package version was downgraded, but now it seems to be bumped to 3.00 again

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions