@helia/verified-fetch
Version:
A fetch-like API for obtaining verified & trustless IPFS content on the web
10 lines • 549 B
TypeScript
import type { VerifiedFetchInit } from '../index.js';
import type { ComponentLogger } from '@libp2p/interface';
/**
* Converts an async iterator of Uint8Array bytes to a stream and returns the first chunk of bytes
*/
export declare function getStreamFromAsyncIterable(iterator: AsyncIterable<Uint8Array>, path: string, logger: ComponentLogger, options?: Pick<VerifiedFetchInit, 'onProgress' | 'signal'>): Promise<{
stream: ReadableStream<Uint8Array>;
firstChunk: Uint8Array;
}>;
//# sourceMappingURL=get-stream-from-async-iterable.d.ts.map