declare global {
    interface ReadableStream<R = any> {
        [Symbol.asyncIterator](): {
            next(): Promise<IteratorResult<R, undefined>>;
            throw?(e?: unknown): Promise<IteratorResult<R, undefined>>;
            return?(): Promise<IteratorResult<R, undefined>>;
            [Symbol.asyncIterator](): any;
        };
    }
}
export type SseMessage<T> = {
    data?: T | undefined;
    event?: string | null | undefined;
    id?: string | null | undefined;
    retry?: number | null | undefined;
};
export declare class EventStream<T extends SseMessage<unknown>> extends ReadableStream<T> {
    constructor(responseBody: ReadableStream<Uint8Array>, parse: (x: SseMessage<string>) => IteratorResult<T, undefined>, opts?: {
        dataRequired?: boolean;
    });
    [Symbol.asyncIterator](): ReturnType<ReadableStream<T>[typeof Symbol.asyncIterator]>;
}
//# sourceMappingURL=event-streams.d.ts.map