import type { Compiler, Configuration, Stats, Watching } from 'webpack'; export type CompilerServerState = 'idle' | 'ready'; export type StatsObjectOptions = Exclude; export type CallbackKey = 'done' | 'watchRun' | 'invalid'; export type CallbackValue = ((stats?: Stats, error?: Error | Error[]) => void) | undefined; export type BaseCompilerWatchingContext = { compiler: Compiler; watching?: Watching; state: CompilerServerState; callbacks: { [key in CallbackKey]: CallbackValue[]; }; stats?: Stats; }; export declare const normalizeStatsOptions: (statsOptions: Configuration["stats"]) => StatsObjectOptions; export declare abstract class BaseCompilerWatching { private context; constructor(compiler: Compiler); setupWatching(): void; isReady(): boolean; setCallback(key: CallbackKey, callback: CallbackValue): void; invalidate(): Promise; resume(): Promise; suspend(): Promise; close(): Promise; }