Hi Sung! Thank you for this post. I tried both your suggestion and Halim's suggestion underneath about how to solve this via custom Netlify build command, and neither worked. I'm new to React and Routing so if you could please have a look at my code and see if I could solve this I would appreciate it extremely.
If you click on a country and try to refresh the page, you either get a blank white page or a 404 error on Netlify. Again, any help would be appreciated immensely!
EDIT: I suspect it might have something to do with the fact that I am using generated paths using a variable (e.g. path="/:countryCode") along with the useParams hook on the target component. Still, if you have any ideas that'd be great!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi Sung! Thank you for this post. I tried both your suggestion and Halim's suggestion underneath about how to solve this via custom Netlify build command, and neither worked. I'm new to React and Routing so if you could please have a look at my code and see if I could solve this I would appreciate it extremely.
Here is the site: hjp-world.netlify.app
And here is the github repo: github.com/hermesjpappas/react-cou...
If you click on a country and try to refresh the page, you either get a blank white page or a 404 error on Netlify. Again, any help would be appreciated immensely!
EDIT: I suspect it might have something to do with the fact that I am using generated paths using a variable (e.g. path="/:countryCode") along with the useParams hook on the target component. Still, if you have any ideas that'd be great!