Resolve routing problem in your React App when you deploy to Netlify

Mbonu Blessing - Feb 26 '20 - - Dev Community

Hello, everyone. I recently ran into a problem with routing when I deployed my react app to netlify. You may have ran into something like this before

Netlify routing page error

I found and article on freecodecamp which gave me a baseline but didn't provide a solution I needed. The article focused on deploying through the netlify cli and through their drag and drop feature on the UI.

This post is a addon for cases where you want to deploy when you push to github.

The solution is to add a netlify.toml file to root folder of your app with this piece of code and you are good to go...

netlify toml code snippet

. . . . . . . . . . . . . . . . . . . . . .
Terabox Video Player