-
Notifications
You must be signed in to change notification settings - Fork 405
New issue
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
Get the pattern for the current route #500
Comments
you can get the matched route by using: ctx._matchedRoute |
@DY6229 do you know how to get the matched route when using nested routers? In that case the info dissapears |
@ChrisLahaye Yes I encountered the same issue. couldn't find any simple solution to this, except for getting the route by-myself using the |
@DinaYakovlev thank you for your reply. I just stopped using nested routes and attached multiple routers to my webserver. |
If I do
ctx.url
I can get the actual URL like/users/123/456
, but I'd like to suggest a feature where we can get the router pattern that was matched like/users/:idA/:idB
for the current route. Something likectx.router.pattern
.The text was updated successfully, but these errors were encountered: