Reputation: 2125
I created a small Ionic 4 / Angular navigation example application with this tutorial: https://www.youtube.com/watch?v=Yx_xJ4m-JxE
Everything works fine except the router animation. A click on this item with routerDirection="forward"
refreshs the whole page, instead of animating only the new page in.
<ion-menu-toggle auto-hide="false" *ngFor="let p of pages">
<ion-item [href]="p.url" [class.active-item]="selectedPath === p.url" routerDirection="forward">
<ion-label>
{{ p.title }}
</ion-label>
</ion-item>
</ion-menu-toggle>
Do I have to install a package or enable routing animations somewhre?? I'm running the project with ionic serve
.
Upvotes: 0
Views: 1717
Reputation: 1479
Ionic 4 navigate works like angular 6+.
routerLink="/notifications"
or in your case routerLink="[p.url]"
Upvotes: 1