I'm looking for a way to retrieve the path name of the current route as I define it in $routeProvider
, i.e. /customer/:id
.
$location.path()
returns the path, /customer/1
, but not the path name, /customer/:id
.
I have found $route.current.$$route.originalPath
that returns exactly what I need. However, I would like very much to not have to rely on private methods.
Is there a public equivalent of $route.current.$$route.originalPath
?