I\'m making an app with dynamical states, and sometimes I need to resolve the state name from the url.
e.g.: I have /dashboard/user/12268 and I need to
/dashboard/user/12268
The current state can be obtained from $state service. like $state.current Check this api http://angular-ui.github.io/ui-router/site/#/api/ui.router.state.$state
$state.current