@dineug/erd-editor
Version:
Entity-Relationship Diagram Editor
18 lines (17 loc) • 635 B
TypeScript
import { AnyAction } from '@dineug/r-html';
import { Observable } from 'rxjs';
import { EngineContext } from './context';
import { History, HistoryOptions } from './history';
import { Store } from './store';
export type RxStore = Store & {
undo: () => void;
redo: () => void;
history: History;
change$: Observable<Array<AnyAction>>;
};
export type RxStoreOptions = {
getReadonly?: () => boolean;
getHistory?: (options: HistoryOptions) => History;
};
export declare const HISTORY_LIMIT = 2048;
export declare function createRxStore(context: EngineContext, { getReadonly, getHistory }?: RxStoreOptions): RxStore;