Skip to content

Commit

Permalink
fix(NgModule): Use InjectionToken instead of OpaqueToken
Browse files Browse the repository at this point in the history
Closes #155
  • Loading branch information
christopherthielen committed Sep 24, 2017
1 parent 83f7011 commit bfa604c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/uiRouterNgModule.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/** */
import { Ng2StateDeclaration } from "./interface";
import {
NgModule, OpaqueToken, ModuleWithProviders, ANALYZE_FOR_ENTRY_COMPONENTS, Provider, Injector
NgModule, ModuleWithProviders, ANALYZE_FOR_ENTRY_COMPONENTS, Provider, Injector, InjectionToken
} from "@angular/core";
import { CommonModule, LocationStrategy, HashLocationStrategy, PathLocationStrategy } from "@angular/common";
import { _UIROUTER_DIRECTIVES } from "./directives/directives";
Expand All @@ -11,9 +11,9 @@ import { UrlRuleHandlerFn, TargetState, TargetStateDef, UIRouter } from "@uirout
import { _UIROUTER_INSTANCE_PROVIDERS, _UIROUTER_SERVICE_PROVIDERS } from "./providers";

import { ROUTES } from "@angular/router";
/** @hidden */ export const UIROUTER_ROOT_MODULE = new OpaqueToken("UIRouter Root Module");
/** @hidden */ export const UIROUTER_MODULE_TOKEN = new OpaqueToken("UIRouter Module");
/** @hidden */ export const UIROUTER_STATES = new OpaqueToken("UIRouter States");
/** @hidden */ export const UIROUTER_ROOT_MODULE = new InjectionToken("UIRouter Root Module");
/** @hidden */ export const UIROUTER_MODULE_TOKEN = new InjectionToken("UIRouter Module");
/** @hidden */ export const UIROUTER_STATES = new InjectionToken("UIRouter States");
// /** @hidden */ export const ROUTES = UIROUTER_STATES;

export function makeRootProviders(module: StatesModule): Provider[] {
Expand Down
2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
version "5.0.6"
resolved "https://registry.yarnpkg.com/@uirouter/core/-/core-5.0.6.tgz#251e1fc4d6ce8fe47e374bb86971e68a2ef1b323"

"@uirouter/publish-scripts@^1.0.4":
"@uirouter/publish-scripts@^1.0.7":
version "1.0.7"
resolved "https://registry.yarnpkg.com/@uirouter/publish-scripts/-/publish-scripts-1.0.7.tgz#99ffd6aeced41e96b92ccb007342eee5d14b0a9a"
dependencies:
Expand Down

0 comments on commit bfa604c

Please sign in to comment.