伙计们,当我在react-router-dom中使用参数时,我将laravel mix与react一起使用,它无法正常工作并显示404页
<Switch>
<Route path="/" exact component={Home} />
<Route path="/ad/:id" exact component={Ad} />
{!store.getState()?.user && (
<Route path="/login" guest component={Login} />
)}
<Route component={Error} />
</Switch>