How to fix the white screen after build with create-react-app?

前端 未结 5 1593
心在旅途
心在旅途 2021-01-12 14:05

I used react-router-dom and I build my react-app. When I deploy it on the server, I get a blank page and the console is empty.

My App.js is :



        
5条回答
  •  花落未央
    2021-01-12 14:41

    I also had this problem, blank white screen, no errors. None of these answers solved my problem. I'm gonna leave the solution to my problem here, so that someone else like me wont spent 2 hours on a small mistake.

    Just make sure you upload all files in /build folder to the server.

提交回复
热议问题