UNPKG

@ngneat/elf-devtools

Version:

Redux devtools for elf store

39 lines (38 loc) 1.2 kB
import { Observable } from 'rxjs'; declare type Action = { type: string; } & Record<string, any>; declare type ActionsDispatcher = Observable<Action>; interface DevtoolsOptions { maxAge?: number; name?: string; postTimelineUpdate?: () => void; preAction?: () => void; actionsDispatcher?: ActionsDispatcher; logTrace?: boolean; } declare global { interface Window { __REDUX_DEVTOOLS_EXTENSION__: { connect(options: DevtoolsOptions): { send(data: { type: string; } & Record<string, any>, state: Record<string, any>): void; init(state: Record<string, any>): void; unsubscribe(): void; subscribe(cb: (message: { type: string; payload: { type: string; }; state: string; }) => void): () => void; }; }; } } export declare function send(action: Action): void; export declare function devTools(options?: DevtoolsOptions): { unsubscribe(): void; } | undefined; export {};