refactor(angular): lazy loading tabs (#16637)

Fixes #16619
This commit is contained in:
Manu MA
2018-12-08 17:23:39 +01:00
committed by GitHub
parent 86fc9a557e
commit 437ad09122
34 changed files with 11361 additions and 246 deletions

View File

@ -2,6 +2,7 @@ import { Injectable } from '@angular/core';
import { Location } from '@angular/common';
import { NavigationExtras, NavigationStart, Router, UrlTree } from '@angular/router';
import { Platform } from './platform';
import { RouterDirection } from '@ionic/core';
export type NavDirection = 'forward' | 'back' | 'root' | 'auto';
@ -10,7 +11,7 @@ export class NavController {
private direction: NavDirection = DEFAULT_DIRECTION;
private animated = DEFAULT_ANIMATED;
private guessDirection: NavDirection = 'forward';
private guessDirection: RouterDirection = 'forward';
private guessAnimation = false;
private lastNavId = -1;
@ -74,7 +75,7 @@ export class NavController {
}
consumeTransition() {
let direction: NavDirection = 'root';
let direction: RouterDirection = 'root';
let animated = false;
if (this.direction === 'auto') {