Created
October 23, 2019 12:45
-
-
Save coffee-cup/5e3ddb0cadf6e34138f24a0b9f12dd33 to your computer and use it in GitHub Desktop.
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
// src/overmind/index.ts | |
import { | |
IConfig, | |
IOnInitialize, | |
IAction, | |
IOperator, | |
IDerive, | |
IState | |
} from 'overmind' | |
export const config = { | |
state: { /* ... */ }, | |
actions: { /* ... */ } | |
} | |
export interface Config extends IConfig<typeof config> {} | |
export interface OnInitialize extends IOnInitialize<Config> {} | |
export interface Action<Input = void, Output = void> extends IAction<Config, Input, Output> {} | |
export interface AsyncAction<Input = void, Output = void> extends IAction<Config, Input, Promise<Output>> {} | |
export interface Operator<Input = void, Output = Input> extends IOperator<Config, Input, Output> {} | |
export interface Derive<Parent extends IState, Output> extends IDerive<Config, Parent, Output> {} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment