You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I was wondering if it was an expected behaviour that useMatch() needs the base url that has been already provided in <Router base="base_url">.
Exemple :
<Routerbase="/foo/bar">
...
</Router>// for a given route '/foo/bar/items/whatever'constmatch=useMatch(()=>"/items/:item_id")console.log(match()?.params.item_id)// undefined (expected 'whatever')constmatch2=useMatch(()=>"/foo/bar/items/:item_id")console.log(match2()?.params.item_id)// 'whatever' (expected undefined because it doesn't match '/foo/bar/foo/bar/items/whatever')
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
I was wondering if it was an expected behaviour that useMatch() needs the base url that has been already provided in
<Router base="base_url">
.Exemple :
Beta Was this translation helpful? Give feedback.
All reactions