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
Following on from this issue #85 could you point me in the right direction where this work might need to be done?
My previous routing logic relied on react-router supporting optional params and not only splitting on a / i.e. my URL could have optional param of .amp
In react-router this works: /:language(${languageRegex})/page/:id(${idRegex}):amp(.amp)?
In navi id & amp get combined into a single param and thus never match correctly
The text was updated successfully, but these errors were encountered:
So basically the way matching works in Navi, is that the remaining part of the route is passed to a mount(), which splits it along the first / character, ignores the second half, and tries to match the first half with each of its supplied patterns.
To support more complex patterns, you'd need to modify this behavior. Here's a few relevant sections of code:
Following on from this issue #85 could you point me in the right direction where this work might need to be done?
My previous routing logic relied on react-router supporting optional params and not only splitting on a
/
i.e. my URL could have optional param of.amp
In react-router this works:
/:language(${languageRegex})/page/:id(${idRegex}):amp(.amp)?
In navi
id
&
get combined into a single param and thus never match correctlyThe text was updated successfully, but these errors were encountered: