interface EventsMap { [event: string]: any; } interface DefaultEvents extends EventsMap { [event: string]: (...args: any) => void; } interface EventEmitter { emit(this: this, event: K, ...args: Parameters): void; events: Partial<{ [E in keyof Events]: Events[E][]; }>; on(this: this, event: K, cb: Events[K]): () => void; } type DefaultEmitter = EventEmitter; declare const createEvents: () => EventEmitter; interface CreateResolverOptions { emitter: DefaultEmitter; evaluate: () => void; eventId: string; failHandler?: Error | false; methodName: string; onFallback?: () => void; } declare const createResolver: ({ emitter, evaluate, eventId, failHandler, methodName, onFallback, }: CreateResolverOptions) => Promise; declare const createRandomId: (size?: number) => string; declare const equals: (a: any, b: any) => boolean; declare const noop: () => void; declare const removeUndefinedKeys: (obj: Record) => Record; declare const timeout: (ms: number, throwOnError?: boolean) => Promise; declare class NativeMethodError extends Error { constructor(methodName: string); } declare const deserializeError: (value: any, ErrorConstructor?: ErrorConstructor) => any; export { type CreateResolverOptions, type DefaultEmitter, type DefaultEvents, type EventEmitter, NativeMethodError, createEvents, createRandomId, createResolver, deserializeError, equals, noop, removeUndefinedKeys, timeout };