export type FetchTemplateOptions = { /** * - HTTP method to use (GET, POST, etc.). */ method?: string; /** * - Request body (only for methods like POST, PUT). */ body?: any; /** * - Timeout in milliseconds (ignored if signal is provided). */ timeout?: number; /** * - Number of retry attempts (ignored if signal is provided). */ retries?: number; /** * - Additional headers. */ headers?: Headers | Record; /** * - External AbortSignal; disables timeout and retries. */ signal?: AbortSignal | null; /** * - Track the load progress. */ onProgress?: import('../html.mjs').FetchOnProgressResult; }; /** * Loads and parses a JSON from a remote URL using Fetch API. * * @param {string} url - The full URL to fetch JSON from. * @param {FetchTemplateOptions} [options] - Optional settings. * @returns {Promise>} Parsed JSON object. * @throws {Error} Throws if fetch fails, times out, or returns invalid JSON. * @deprecated */ export declare function fetchJson(url: string, options?: FetchTemplateOptions): Promise>; /** * Loads a remote file as a Blob using Fetch API. * * @param {string} url - The full URL to fetch the file from. * @param {string[]} [allowedMimeTypes] - Optional list of accepted MIME types (e.g., ['image/jpeg']). * @param {FetchTemplateOptions} [options] - Optional fetch options. * @returns {Promise} - The fetched file as a Blob. * @throws {Error} Throws if fetch fails, response is not ok, or MIME type is not allowed. * @deprecated */ export declare function fetchBlob(url: string, allowedMimeTypes?: string[], options?: FetchTemplateOptions): Promise; /** * Loads a remote file as a text using Fetch API. * * @param {string} url - The full URL to fetch the file from. * @param {string[]} [allowedMimeTypes] - Optional list of accepted MIME types (e.g., ['image/jpeg']). * @param {FetchTemplateOptions} [options] - Optional fetch options. * @returns {Promise} - The fetched file as a text. * @throws {Error} Throws if fetch fails, response is not ok, or MIME type is not allowed. * @deprecated */ export declare function fetchText(url: string, allowedMimeTypes?: string[], options?: FetchTemplateOptions): Promise; //# sourceMappingURL=html.d.mts.map