Examples for ionic with angular 2 router

The navigation on Ionic 2 wanted to be near to the way Native development works, and it’s pretty intuitive and easy to use IMHO. We’ll see how they integrate the Angular Router in the next releases.

Hi,

I would like to know what is the status of integrating with the new @angular/router version 3.0.0-beta.2? Do you have any tentative dates yet, or a rough time frame? I consider using Ionic for a hybrid app, where the Web app interface is just as important as the mobile interface, and therefore support for URL-navigation is key.

Furthermore, I would suspect that the @angular/router integration will still support a stack-based history, since that is how browsers usually organize their history.

We’re waiting news about the beta.11 milestone status from @mhartington, I’m not sure if router is included in the next release, only heard about performance improvements for sure.

Thanks for the quick reply, @matheo. I guess I’ll have to give it another week and see then. Another reason I look forward to (or, think I need) the @angular/router integration is that the canActivate guards in the new Angular 2 router seem really helpful for implementing authentication and authorization for accessing particular components of an app (https://angular.io/docs/ts/latest/guide/router.html#guards).

Indeed, that’s cool stuff, we’ll see how the Ionic team integrates it, I trust em a lot because they have done an excellent job on this new version :sunglasses:

2 Likes

I’m looking forward to using routing to

  1. make debug easier by providing debug short cuts directly from the url, testability will be a lot easier, manual or automated
  2. simplify navigation, using [routeLink]=’["/view/124"]’ on an ion-item under different contexts eliminates the need of writing handlers - often multiple times.
1 Like

No news about angular router?? We all still need it asap! :confused:

Same here, it would be interesting to have angular router examples or at least have the server able to serve index.html regardless of the route provided.

@linvi the angular2 router will not be integrated into ionic2, but they will integrate a new routing system coming shortly.

1 Like

Any word on when this is coming? Based on this commit history, I don’t see it being worked on: https://github.com/driftyco/ionic/compare/v2.0.0-beta.11...master

@brandyshea can you share some more infos with us?

@brandyshea @max @adam How we will be handling URLs in PWA apps and also i think its needed for SEO also for mobile websites !
Can anyone from Ionic team comment over this about how we will be going about this in future any roadmap for this ?

2 Likes

@mtrtm Can you please advice something on Authorization if you tried it with Ionic ? As, still now we don’t have much update on angular router.

Hi @gaurav,

I haven’t started implementing the authorization stuff yet, exactly because I’m waiting for the integration of the new Angular 2 router in the Ionic framework. I’ve done back-end development in the mean time.

thanks @mtrtm for prompt reply :slight_smile:
I am hoping to see updates, if you get any please update here for all of us.

1 Like

Hello Guys any update on this issue? Is routing back yet? Or any workaround?

Waiting for update on routing too.

Me too - I would like to use Ionic 2 also for regular web apps and not only mobile applications :frowning:

It seems in rc.0 there is no new ionic url router

So we still don’t know what’s going on or what we could expect.

3 Likes

See this link for more details about router

4 Likes