React App Client Side Routing Not working

I have followed the documentation here : Create React App
But my rewrite rule doesn’t seem to be working.

Even after deleting the rule, my webpage is still rendering a blank page.

I have tested the app locally with the build version, and it seems to be working fine.
I am using react-router to handle the client side routing.

1 Like

I’m about to start a similar project so wanted to investigate. I created a simple demo react-router app (render-create-react-app-demo/App.js at master · johnbeynon/render-create-react-app-demo · GitHub). When deployed the app loaded and I was able to click the links rendered. Visiting a path directly failed (as expected) so I added the route as in the linked documentation and it then loaded successfully via the URL.

Whilst this doesn’t help you, it does at least confirm that the documentation is correct. You should at least see your app and be able to navigate it successfully WITHOUT the rule, it’s only if you enter a URL directly in the address bar does the rewrite rule take effect.

Let me know,
John.

Have the same problem. Did you solve it?