fix(router): export missing UrlMatcher and UrlMatchResult types

Fixes #15140
This commit is contained in:
Igor Minar 2017-06-24 00:08:18 -07:00 committed by Jason Aden
parent 6282a86135
commit 578bdeb522
2 changed files with 12 additions and 1 deletions

View File

@ -7,7 +7,7 @@
*/
export {Data, LoadChildren, LoadChildrenCallback, ResolveData, Route, Routes, RunGuardsAndResolvers} from './config';
export {Data, LoadChildren, LoadChildrenCallback, ResolveData, Route, Routes, RunGuardsAndResolvers, UrlMatchResult, UrlMatcher} from './config';
export {RouterLink, RouterLinkWithHref} from './directives/router_link';
export {RouterLinkActive} from './directives/router_link_active';
export {RouterOutlet} from './directives/router_outlet';

View File

@ -476,6 +476,17 @@ export declare abstract class UrlHandlingStrategy {
abstract shouldProcessUrl(url: UrlTree): boolean;
}
/** @experimental */
export declare type UrlMatcher = (segments: UrlSegment[], group: UrlSegmentGroup, route: Route) => UrlMatchResult;
/** @experimental */
export declare type UrlMatchResult = {
consumed: UrlSegment[];
posParams?: {
[name: string]: UrlSegment;
};
};
/** @stable */
export declare class UrlSegment {
readonly parameterMap: ParamMap;