在 laravel 中使用动态路由时单击惯性链接时,我找不到导航到新页面的方法。
路线:
This two is not added together in the code. I tried both way to tested so i put both here
Route::get('/{clothesCategory}', 'ClothesController@getCalsas'); // this doesnt work
Route::get('/NotDynamic, 'ClothesController@getCalsas'); // this work
html:
<inertia-link href="/NotDynamic">Not Working</inertia-link> //this only works with NotDynamic route
<a href="/NotDynamic">Working</a> // this works with both routes
为什么会发生这种情况我不明白背后的原因?还有我怎样才能让惯性链接与动态路线一起工作?