-
Notifications
You must be signed in to change notification settings - Fork 59
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(globals): Removed
UIRouterGlobals
interface. Renamed Globals
…
… class to `UIRouterGlobals` BREAKING CHANGE: This change will likely only affect a small subset of typescript users and probably only those using `ui-router-ng2`. If you're injecting the `Globals` class somewhere, e.g.: ``` @Injectable() class MyService { _globals: UIRouterGlobals; constructor(globals: Globals) { this._globals = <UIRouterGlobals> globals; } } ``` you should now inject `UIRouterGlobals`, e.g.: ``` @Injectable() class MyService { constructor(public globals: UIRouterGlobals) { } } ``` Likewise, if you were casting the `UIRouter.globals` object as a `UIRouterGlobals`, it is no longer necessary: ```js function myHook(trans: Transition) { let globals: UIRouterGlobals = trans.router.globals; // cast is no longer necessary } ``` Closes #31
- Loading branch information
1 parent
7f078c4
commit 8719334
Showing
6 changed files
with
22 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,7 @@ karma.**.js | |
tslint.json | ||
tsconfig.json | ||
tsconfig.*.json | ||
yarn.lock | ||
|
||
*.iml | ||
*.ipr | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters