feat(core): upgrade rxjs to 6.0.0-alpha.4 (#22573)

PR Close #22573
This commit is contained in:
Igor Minar
2018-02-27 17:06:06 -05:00
parent c445314239
commit b43f8bc7d3
270 changed files with 10104 additions and 1860 deletions

View File

@ -8,14 +8,15 @@
import {LocationStrategy} from '@angular/common';
import {Attribute, Directive, ElementRef, HostBinding, HostListener, Input, OnChanges, OnDestroy, Renderer2, isDevMode} from '@angular/core';
import {Subscription} from 'rxjs/Subscription';
import {Subscription} from 'rxjs';
import {QueryParamsHandling} from '../config';
import {NavigationEnd} from '../events';
import {NavigationEnd, RouterEvent} from '../events';
import {Router} from '../router';
import {ActivatedRoute} from '../router_state';
import {UrlTree} from '../url_tree';
/**
* @whatItDoes Lets you link to specific parts of your app.
*
@ -184,7 +185,7 @@ export class RouterLinkWithHref implements OnChanges, OnDestroy {
constructor(
private router: Router, private route: ActivatedRoute,
private locationStrategy: LocationStrategy) {
this.subscription = router.events.subscribe(s => {
this.subscription = router.events.subscribe((s: RouterEvent) => {
if (s instanceof NavigationEnd) {
this.updateTargetUrlAndHref();
}

View File

@ -7,11 +7,14 @@
*/
import {AfterContentInit, ChangeDetectorRef, ContentChildren, Directive, ElementRef, Input, OnChanges, OnDestroy, QueryList, Renderer2, SimpleChanges} from '@angular/core';
import {Subscription} from 'rxjs/Subscription';
import {NavigationEnd} from '../events';
import {Subscription} from 'rxjs';
import {NavigationEnd, RouterEvent} from '../events';
import {Router} from '../router';
import {RouterLink, RouterLinkWithHref} from './router_link';
/**
* @whatItDoes Lets you add a CSS class to an element when the link's route becomes active.
*
@ -93,7 +96,7 @@ export class RouterLinkActive implements OnChanges,
constructor(
private router: Router, private element: ElementRef, private renderer: Renderer2,
private cdr: ChangeDetectorRef) {
this.subscription = router.events.subscribe(s => {
this.subscription = router.events.subscribe((s: RouterEvent) => {
if (s instanceof NavigationEnd) {
this.update();
}