【发布时间】:2021-08-16 22:49:47
【问题描述】:
我有一个包含一些组件的反应应用程序网站。 我想通过 url 地址直接导航到我的应用中的特定位置。
这是网站网址:https://baryogo.co.il
这是我的路线:
<Route path='/home' component={Menu} /> <Route path='/contactus' component={Contactus} /> {/* <Route path='/ourservices' component={OurServices} /> */} <Route path='/gallery' component={Gallerya} /> <Route path='/ourcustomers' component={OurCustomers} /> <Route exact path="/view-category-details/:id" component={ViewCategoryDetails} /> <Route exact path="/view-category-images/:title" component={ViewCategoryImages} />
例如,当我尝试访问 www.baryogo.co.il/gallery 时,它是有效的,
但是当我尝试直接访问具有特定 id 或标题的 view-category-details 或 view-category-images 时,它显示为空白。
【问题讨论】:
标签: reactjs