react-router V6踩坑

useRoutes() may be used only in the context of a <Router> component.
需要将BrowserRouter放到外层,放到APP外层即可

 

posted @ 2022-04-06 15:49  红苹果学园  阅读(364)  评论(0编辑  收藏  举报