http://stackoverflow.com/questions/34479405/angular2-get-current-routes-alias

On Wednesday, December 30, 2015 at 12:27:06 AM UTC+1, Manfred Steyer wrote:
>
> Hi,
>
> currently, I use the Location-Service to find out, what the current route 
> is:
>
> isActive(path): boolean {
>     if (path == '') return this.location.path() == '';  
>     return (this.location.path().startsWith(path));
> }
>
> But I'm looking for a better way of doing so, cause in this case, I'm 
> working with the url (that might change during development) and not with 
> the internal route-name.
>
> Is there a way to get the name of the current route?
>
> Wishes,
> Manfred
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to