0

I created my react app using npx create-react-app my-app but when I try to load the web application on IE11, it just prints a blank page.

I also added the polyfill by installing using the command yarn add react-app-polyfill and then including the following :

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

inside src/index.tsx. But still it loads the blank page. What should I do? I have no clue on how to proceed.

Amanda
  • 2,013
  • 3
  • 24
  • 57
  • I suspect even without the polyfill that even a brand new, freshly initialized, created react app should render *something*. Any warnings/errors in the log? You ran `npm i` to install the dependencies, and you're running `npm start` to build and start the local dev server? – Drew Reese Mar 31 '20 at 06:50
  • @DrewReese Yes I did that but just a blank screen without any console errors – Amanda Mar 31 '20 at 07:02

1 Answers1

0

What is your react-scripts version? There're some issues with react-scripts version 3.3.0 and higher. You could find many issue reports in GitHub, for example: github.com/facebook/create-react-app/issues/8197, github.com/facebook/create-react-app/issues/8195.

It can still work with react-scripts@3.2.0. You could try to revert back to 3.2.0 as a workaround. Please also remember to have polyfills for IE, delete .cache folder in node_modules and delete IE browser cache then try again.

Yu Zhou
  • 11,532
  • 1
  • 8
  • 22