-
-
Notifications
You must be signed in to change notification settings - Fork 27k
Application crashes on IE11 and lower, Syntax error #5832
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
Comments
Do you have a required polyfill included as the very first line in your |
|
I ran - npm run build, and then served built aplication using Express locally - it works perfectly on IE11 :) So the problem seems to happen only with npm start |
You need to configure the |
I'm having the same issue. Any updates are appreciated. |
To those who end up here, I found success using babel-engine-plugin to transpile the necessary node_modules for ie11. |
you dont need transpile node_modules, if |
It is a known issue that the development version ( |
This is true unless you're using |
Any updates on this? Is it planned to make the development version After copy/pasting the polyfill lines from the https://github.com/facebook/create-react-app/tree/master/packages/react-app-polyfill I believe many devs try to |
One of my older apps was still working and it was on react-scripts @ v2.1.5 so I just downgraded my react-scripts to |
@StJohn3D thanks it's working fine if I update version to "react-scripts": "2.1.5" |
@Luke93dev @jackblackCH @newtonanbarasu and anyone else arriving here, there is a better solution outlined here: #6924 (comment) |
If you're still stuck, hopefully this helps: https://medium.com/@matwankarmalay/create-react-app-ie11-script1002-syntax-error-how-to-get-rid-of-it-d70000c53ddf |
Using React scripts 5.0.0, what worked for me on IE 11 was:
|
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
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.
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
The text was updated successfully, but these errors were encountered: