angular / router

The Angular 1 Component Router
MIT License
665 stars 135 forks source link

Programmatically navigation in new router #361

Closed ghost closed 9 years ago

ghost commented 9 years ago

What's the "official" programmatic equivalent of ng-link to execute from within your controller? Whether with the basic router or the ui-router, and now with the new router, we rarely declare links directly in the markup. More typically, we click something, do something, then programmatically navigate.

rhllor commented 9 years ago

same issue. Any solution?

offboarded-x233534 commented 9 years ago

I also would like to know how this works.

0x-r4bbit commented 9 years ago

It's router.navigate() or router.navigateByUrl() depending on what you have available to route to a component.

Also keep in mind that this repo here is on hold and that all the development is happening over at http://github.com/angular/angular.

offboarded-x233534 commented 9 years ago

ok and thanks a lot :)