I working on route level access, need to get path
from route
object like /history/:id
. If I am using route.path
or route.get('path')
both not working.
route: Route {
path: '/history/:id',
stack: [ [Layer], [Layer] ],
methods: { get: true }
}
if (typeof req.route === 'object') {
console.log(req.route.path);
}