React Router deep linking

后端 未结 1 1258
暗喜
暗喜 2021-02-05 17:34

This is my first time using React and React Router, and I am running into some deep linking issues. I\'ve build a simple SPA, and with the help of React Router, I can navigate t

相关标签:
1条回答
  • 2021-02-05 17:50

    You can traverse the site from your root since the routing is all handled by react-router which loaded from your root site's js files.

    There is no html file located in /about/index.html. gh-pages hosts static sites, and if you go to mysite.com/about without having the html file, it will probably give you a 404.

    If you're using webpack, try using https://github.com/markdalgleish/static-site-generator-webpack-plugin.

    0 讨论(0)
提交回复
热议问题