Search code examples
reactjsinternet-explorerwebpackcreate-react-apppolyfills

Why React app is not working in Internet Explorer browser


React App is not Working in internet explorer at all, i have used multiple solution for this issue but not got any solution.

  1. npm i react-app-polyfill --save
  2. add below files in index.js

    import 'react-app-polyfill/ie9'; import 'react-app-polyfill/ie11'; import 'react-app-polyfill/stable';

  3. In package.json and add "ie 11" into "browserslist->development" section:

*

"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"ie 11",
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
  1. delete .cache in node_modules
  2. npm start

Thanks in Advance


Solution

  • Please open the package.json file and check whether you are using "react-scripts": "3.3.0" or greater?

    I have seen many users are having similar issues nowadays.

    If you are using "react-scripts": "3.3.0" or greater then try to use "react-scripts": "3.2.0". It can help to fix this issue.

    Try to clear node_modules/.cache after making this change.

    References:

    1. Default create-react-app does not work in IE despite polyfills and browser list

    2. “react-app-polyfill” doesn't work in IE11

    3. IE11 support doesn't work in dev mode, even after adding all polyfills and enabling ie11 support #8197

    4. Why application created using create-react-app is not working in IE browser? #8195