Skip to content

Commit

Permalink
refactor(state): improves get typings
Browse files Browse the repository at this point in the history
  • Loading branch information
rafamel committed Apr 24, 2019
1 parent 0ebea9a commit f4c0972
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/state/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export default {
this.setOptions();
}
},
get(key: keyof TState): any {
get<T extends keyof TState>(key: T): TState[T] {
return state[key];
},
paths(): Promise<IPaths> {
Expand Down

0 comments on commit f4c0972

Please sign in to comment.