Skip to content

Commit

Permalink
Merge pull request #613 from bigopon/fix-build
Browse files Browse the repository at this point in the history
fix(typings): Revert aliasing interface
  • Loading branch information
EisenbergEffect authored Aug 7, 2018
2 parents ddb9be1 + 2816647 commit 8f97f35
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
5 changes: 0 additions & 5 deletions src/interfaces.js
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,3 @@ interface PipelineResult {
output: any;
completed: boolean;
}

/**
* The result of a router navigation.
*/
export type NavigationResult = Promise<PipelineResult | boolean>;
6 changes: 3 additions & 3 deletions src/router.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
_createRootedPath,
_resolveUrl
} from './util';
import {RouteConfig, NavigationResult} from './interfaces';
import {RouteConfig, PipelineResult} from './interfaces';

/**
* The primary class responsible for handling routing and navigation.
Expand Down Expand Up @@ -218,7 +218,7 @@ export class Router {
* @param fragment The URL fragment to use as the navigation destination.
* @param options The navigation options.
*/
navigate(fragment: string, options?: NavigationOptions): NavigationResult {
navigate(fragment: string, options?: NavigationOptions): Promise<PipelineResult | boolean> {
if (!this.isConfigured && this.parent) {
return this.parent.navigate(fragment, options);
}
Expand All @@ -235,7 +235,7 @@ export class Router {
* @param params The route parameters to be used when populating the route pattern.
* @param options The navigation options.
*/
navigateToRoute(route: string, params?: any, options?: NavigationOptions): NavigationResult {
navigateToRoute(route: string, params?: any, options?: NavigationOptions): Promise<PipelineResult | boolean> {
let path = this.generate(route, params);
return this.navigate(path, options);
}
Expand Down

0 comments on commit 8f97f35

Please sign in to comment.