React-router urls don't work when refreshing or writing manually

My small project is live:

Landing page( has a form which takes in username & shows github profile of that user with URL changed(for e.g

Everything is fine till here but if refresh this page or manually type this URL in a new tab then all I get is a white blank page.

I read some stack overflow solutions & they suggested to add a _redirects file inside the public folder with content /* /index.html 200. But still no luck.

Help me please.

hey there, this is likely relevant:

I already have a _redirects file with content mentioned above. I’m still stuck with the same issue.

I just removed “homepage” from my package.json & it somehow solved the issue. Works like charm.

1 Like