UNPKG

503 BTypeScriptView Raw
1/// <reference types="node" />
2import { Readable } from 'stream';
3import { UrlWithStringQuery } from 'url';
4import { GetUriOptions } from '.';
5declare class DataReadable extends Readable {
6 hash?: string;
7 constructor(hash: string, buf: Buffer);
8}
9interface DataOptions extends GetUriOptions {
10 cache?: DataReadable;
11}
12/**
13 * Returns a Readable stream from a "data:" URI.
14 */
15export default function get({ href: uri }: UrlWithStringQuery, { cache }: DataOptions): Promise<Readable>;
16export {};