@yoyo-org/progressive-json
Version:
Stream and render JSON data as it arrives - perfect for AI responses, large datasets, and real-time updates
10 lines (9 loc) • 478 B
TypeScript
import { HttpAdapter, HttpAdapterOptions, ExtendedHttpAdapter, HttpAdapterResponse } from './http-adapter';
/**
* Default HTTP adapter using the built-in fetch API
*/
export declare class FetchAdapter implements HttpAdapter, ExtendedHttpAdapter {
stream(url: string, options?: HttpAdapterOptions): Promise<ReadableStream<Uint8Array>>;
request(url: string, options?: HttpAdapterOptions): Promise<HttpAdapterResponse>;
}
export declare const fetchAdapter: FetchAdapter;