Skip to content

Commit ad7c2d4

Browse files
christianalfonigitbook-bot
authored andcommitted
GitBook: [v28] one page modified
1 parent 320da18 commit ad7c2d4

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

core/typescript.md

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,7 @@ import { IContext } from 'overmind'
1313

1414
export const config = {}
1515

16-
// Due to circular typing we have to define an
17-
// explicit typing of state, actions and effects since
18-
// TS 3.9 using a TYPE (not INTERFACE)
19-
export type Context = IContext<{
20-
state: typeof config.state,
21-
actions: typeof config.actions,
22-
effects: typeof config.effects
23-
}>
16+
export type Context = IContext<typeof config>
2417
```
2518
{% endtab %}
2619
{% endtabs %}

0 commit comments

Comments
 (0)