I try to setup nested routes for my react app like this
/
-> Home Page/about
-> About Page/protected
I was having the same problem described in the question (webpack-dev-server not serving nested routes, top level ones working fine). Sadly, neither historyApiFallback: true
nor publicPath: '/'
were working. Actually, the problem was inside index.html
, more precisely inside . Changing to
was enough to end the pain.