Interface ReadableStream<R>

    interface ReadableStream<R = any> {
        locked: boolean;
        "[asyncIterator]"(
            options?: ReadableStreamIteratorOptions,
        ): ReadableStreamAsyncIterator<R>;
        cancel(reason?: any): Promise<void>;
        getReader(options: { mode: "byob" }): ReadableStreamBYOBReader;
        getReader(): ReadableStreamDefaultReader<R>;
        getReader(
            options?: ReadableStreamGetReaderOptions,
        ): ReadableStreamReader<R>;
        pipeThrough<T>(
            transform: ReadableWritablePair<T, R>,
            options?: StreamPipeOptions,
        ): ReadableStream<T>;
        pipeTo(
            destination: WritableStream<R>,
            options?: StreamPipeOptions,
        ): Promise<void>;
        tee(): [ReadableStream<R>, ReadableStream<R>];
        values(
            options?: ReadableStreamIteratorOptions,
        ): ReadableStreamAsyncIterator<R>;
    }

    Type Parameters

    • R = any

    Properties

    locked: boolean

    Methods