diff --git a/docs/angular/lifecycle.mdx b/docs/angular/lifecycle.mdx index 6f3d36efc9..b81bf6461f 100644 --- a/docs/angular/lifecycle.mdx +++ b/docs/angular/lifecycle.mdx @@ -67,6 +67,8 @@ Because of this special handling, the `ngOnInit` and `ngOnDestroy` methods might `ngOnInit` will only fire each time the page is freshly created, but not when navigated back to the page. For instance, navigating between each page in a tabs interface will only call each page's `ngOnInit` method once, but not on subsequent visits. `ngOnDestroy` will only fire when a page "popped". +Navigating forward to a page that is already in the stack works the same way. Ionic returns to the existing page instead of creating a new one, and pops the pages above it. For instance, navigating from `/login` to `/home` and then forward to `/login` again reuses the original login page, so its `ngOnInit` does not fire a second time. Use `ionViewWillEnter` or `ionViewDidEnter` for logic that needs to run on every visit, such as loading data. + ## Route Guards {/* #route-guards */} In Ionic 3, there were a couple of additional life cycle methods that were useful to control when a page could be entered (`ionViewCanEnter`) and left (`ionViewCanLeave`). These could be used to protect pages from unauthorized users and to keep a user on a page when you don't want them to leave (like during a form fill).