@ -5,6 +5,8 @@
|
||||
|
||||
import {makeDecorator} from 'angular2/src/util/decorators';
|
||||
import {CanActivate as CanActivateAnnotation} from './lifecycle_annotations_impl';
|
||||
import {Promise} from 'angular2/src/facade/async';
|
||||
import {Instruction} from 'angular2/src/router/instruction';
|
||||
|
||||
export {
|
||||
canReuse,
|
||||
@ -14,4 +16,6 @@ export {
|
||||
onDeactivate
|
||||
} from './lifecycle_annotations_impl';
|
||||
|
||||
export var CanActivate = makeDecorator(CanActivateAnnotation);
|
||||
export var CanActivate:
|
||||
(hook: (next: Instruction, prev: Instruction) => Promise<boolean>| boolean) => ClassDecorator =
|
||||
makeDecorator(CanActivateAnnotation);
|
||||
|
@ -9,6 +9,6 @@ export class LocationStrategy {
|
||||
pushState(ctx: any, title: string, url: string): void { throw _abstract(); }
|
||||
forward(): void { throw _abstract(); }
|
||||
back(): void { throw _abstract(); }
|
||||
onPopState(fn: (_) => any): void { throw _abstract(); }
|
||||
onPopState(fn: (_: any) => any): void { throw _abstract(); }
|
||||
getBaseHref(): string { throw _abstract(); }
|
||||
}
|
||||
|
@ -1,5 +1,7 @@
|
||||
import {RouteConfig as RouteConfigAnnotation} from './route_config_impl';
|
||||
import {RouteConfig as RouteConfigAnnotation, RouteDefinition} from './route_config_impl';
|
||||
import {makeDecorator} from 'angular2/src/util/decorators';
|
||||
import {List} from 'angular2/src/facade/collection';
|
||||
|
||||
export {Route, Redirect, AsyncRoute, RouteDefinition} from './route_config_impl';
|
||||
export var RouteConfig = makeDecorator(RouteConfigAnnotation);
|
||||
export var RouteConfig: (configs: List<RouteDefinition>) => ClassDecorator =
|
||||
makeDecorator(RouteConfigAnnotation);
|
||||
|
Reference in New Issue
Block a user