import { IReactionDisposer } from 'mobx'; import Cache from './Cache'; export default class PromiseMerger { timeout: number; cache: Cache; promiseList: { [key: string]: { resolves: Function[]; rejects: Function[]; }; }; waitID: any; callback: (codes: any) => Promise<{ [key: string]: V; }>; reaction: IReactionDisposer; constructor(callback: (codes: any) => Promise<{ [key: string]: V; }>, config: any, timeout?: number); dispose(): void; add(code: string): Promise; }