We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi guys, the following routing
<Router> <Route path="/" component={App}/> <Route path="/aRoute" component={App}> <Route path=":myParam" /> </Route> </Router>
doesn't value routeParams when navigating to "/aRoute/1"
routeParams is valued if I use optional parameters as follow
<Router> <Route path="/" component={App}/> <Route path="/aRoute(/:myParam)" component={App}/> </Router>
looks like a bug to me, is it an intended behaviour?
tested against version 3.0.0
below a runnable version of both scenarios
nested routes: http://codepen.io/anon/pen/QGqWQW?editors=001 optional parameters: http://codepen.io/anon/pen/eBGYyd?editors=001
The text was updated successfully, but these errors were encountered:
From the docs:
routeParams A subset of this.props.params that were directly specified in this component's route.
routeParams
A subset of this.props.params that were directly specified in this component's route.
If your <Route path=":myParam" /> had a component, that component would have access to props.routeParams.myParam.
<Route path=":myParam" />
props.routeParams.myParam
Sorry, something went wrong.
Thanks for the quick response,
I noticed this thing refactoring some route with optional parameters to nested routes. I did it because of the following issue with the isActive API
3277
I was expecting nothing to break and no need to change the components implementation doing that change.
Maybe a little extra to that line in the doc would not be bad, that route is rendering that component after all :)
No branches or pull requests
Hi guys, the following routing
doesn't value routeParams when navigating to "/aRoute/1"
routeParams is valued if I use optional parameters as follow
looks like a bug to me, is it an intended behaviour?
tested against version 3.0.0
below a runnable version of both scenarios
nested routes: http://codepen.io/anon/pen/QGqWQW?editors=001
optional parameters: http://codepen.io/anon/pen/eBGYyd?editors=001
The text was updated successfully, but these errors were encountered: