Skip to content

Commit

Permalink
refactor(router): update types
Browse files Browse the repository at this point in the history
  • Loading branch information
jwx committed Oct 2, 2019
1 parent f964761 commit 22d15f3
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/router/src/guard.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { Constructable } from '@aurelia/kernel';
import { GuardIdentity, GuardTypes, IGuardOptions, } from './guardian';
import { ComponentAppellation, GuardFunction, GuardTarget, IComponentAndOrViewportOrNothing, INavigatorInstruction, IRouteableComponentType } from './interfaces';
import { GuardFunction, GuardTarget, IComponentAndOrViewportOrNothing, INavigatorInstruction, IRouteableComponentType } from './interfaces';
import { ComponentAppellationResolver, ViewportHandleResolver } from './type-resolvers';
import { Viewport } from './viewport';
import { ViewportInstruction } from './viewport-instruction';
Expand Down Expand Up @@ -57,7 +56,9 @@ class Target {
} else {
const cvTarget = target as IComponentAndOrViewportOrNothing;
if (cvTarget.component) {
this.componentType = ComponentAppellationResolver.isType(cvTarget.component) ? ComponentAppellationResolver.getType(cvTarget.component as ComponentAppellation) : null;
this.componentType = ComponentAppellationResolver.isType(cvTarget.component)
? ComponentAppellationResolver.getType(cvTarget.component)
: null;
this.componentName = ComponentAppellationResolver.getName(cvTarget.component);
}
if (cvTarget.viewport) {
Expand Down

0 comments on commit 22d15f3

Please sign in to comment.