UNPKG

@codex-storage/sdk-js

Version:

Codex SDK to interact with the Codex decentralized storage network.

18 lines (15 loc) 616 B
import { l as UploadStategy, k as UploadStategyOptions, S as SafeValue } from './types-C5Toly_l.js'; import 'valibot'; declare class BrowserUploadStategy implements UploadStategy { private readonly file; private readonly onProgress; private readonly metadata; private xhr; constructor(file: Document | XMLHttpRequestBodyInit, onProgress?: (loaded: number, total: number) => void, metadata?: { filename?: string; mimetype?: string; }); upload(url: string, { auth }: UploadStategyOptions): Promise<SafeValue<string>>; abort(): void; } export { BrowserUploadStategy };