Files
SnowLuma/.pnpm-store/v11/files/bd/da32c2e60d3a76b009862df06681529d3fc9bd02147a9275f4d46555d7fdcd1f98aefff78670d094d2bb25ea6d81dc53c9bf4455c72ccdf776ec4442be0a47
T
TanTan 2a69b23b47
Dev Build / cleanup (push) Waiting to run
Dev Build / typecheck (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:27:07 +08:00

37 lines
1.1 KiB
Plaintext

//#region src/client/fetch-result-please.d.ts
/**
* @description This file is a modified version of `fetch-result-please` (`ofetch`), minimalized and adapted to Hono's custom needs.
*
* @link https://www.npmjs.com/package/fetch-result-please
*/
/**
* Smartly parses and return the consumable result from a fetch `Response`.
*
* Throwing a structured error if the response is not `ok`. ({@link DetailedError})
*/
export declare function fetchRP(fetchRes: Response | Promise<Response>): Promise<any>;
export declare class DetailedError extends Error {
/**
* Additional `message` that will be logged AND returned to client
*/
detail?: any;
/**
* Additional `code` that will be logged AND returned to client
*/
code?: any;
/**
* Additional value that will be logged AND NOT returned to client
*/
log?: any;
/**
* Optionally set the status code to return, in a web server context
*/
statusCode?: any;
constructor(message: string, options?: {
detail?: any;
code?: any;
statusCode?: number;
log?: any;
});
}
//#endregion