diff --git a/modules/@angular/router/index.ts b/modules/@angular/router/index.ts index 6e21a68b73..7ef0315d0e 100644 --- a/modules/@angular/router/index.ts +++ b/modules/@angular/router/index.ts @@ -13,7 +13,7 @@ export {RouterLink, RouterLinkWithHref} from './src/directives/router_link'; export {RouterLinkActive} from './src/directives/router_link_active'; export {RouterOutlet} from './src/directives/router_outlet'; export {CanActivate, CanActivateChild, CanDeactivate, Resolve} from './src/interfaces'; -export {Event, NavigationCancel, NavigationEnd, NavigationError, NavigationStart, Router, RoutesRecognized} from './src/router'; +export {Event, NavigationCancel, NavigationEnd, NavigationError, NavigationExtras, NavigationStart, Router, RoutesRecognized} from './src/router'; export {ROUTER_DIRECTIVES, RouterModule} from './src/router_module'; export {RouterOutletMap} from './src/router_outlet_map'; export {provideRouter} from './src/router_providers'; diff --git a/modules/@angular/router/src/directives/router_outlet.ts b/modules/@angular/router/src/directives/router_outlet.ts index f394c9c4bd..48fa44b4ed 100644 --- a/modules/@angular/router/src/directives/router_outlet.ts +++ b/modules/@angular/router/src/directives/router_outlet.ts @@ -6,13 +6,14 @@ * found in the LICENSE file at https://angular.io/license */ -import {Attribute, ComponentFactory, ComponentFactoryResolver, ComponentRef, Directive, EventEmitter, NoComponentFactoryError, Output, ReflectiveInjector, ResolvedReflectiveProvider, ViewContainerRef, Injector} from '@angular/core'; +import {Attribute, ComponentFactory, ComponentFactoryResolver, ComponentRef, Directive, EventEmitter, Injector, NoComponentFactoryError, Output, ReflectiveInjector, ResolvedReflectiveProvider, ViewContainerRef} from '@angular/core'; import {RouterOutletMap} from '../router_outlet_map'; import {ActivatedRoute} from '../router_state'; import {PRIMARY_OUTLET} from '../shared'; + /** * A router outlet is a placeholder that Angular dynamically fills based on the application's route. * diff --git a/modules/@angular/router/src/router.ts b/modules/@angular/router/src/router.ts index 2c19452f49..913ad39a1a 100644 --- a/modules/@angular/router/src/router.ts +++ b/modules/@angular/router/src/router.ts @@ -38,6 +38,9 @@ import {TreeNode} from './utils/tree'; declare var Zone: any; +/** + * @experimental + */ export interface NavigationExtras { relativeTo?: ActivatedRoute; queryParams?: Params; diff --git a/tools/public_api_guard/router/index.d.ts b/tools/public_api_guard/router/index.d.ts index e85a3bbe62..40cec17341 100644 --- a/tools/public_api_guard/router/index.d.ts +++ b/tools/public_api_guard/router/index.d.ts @@ -79,6 +79,13 @@ export declare class NavigationError { toString(): string; } +/** @experimental */ +export interface NavigationExtras { + fragment?: string; + queryParams?: Params; + relativeTo?: ActivatedRoute; +} + /** @stable */ export declare class NavigationStart { id: number;