FetchFunction: (
input: string | URL | Request,
init?: RequestInit,
) => Promise<Response>
Type Declaration
- (input: string | URL | Request, init?: RequestInit): Promise<Response>
Parameters
- input: string | URL | Request
Optionalinit: RequestInit
Returns Promise<Response>
A function that can stand in for the global
fetch. Narrower thantypeof fetch, which under Bun's types also demands static members such aspreconnectthat a wrapper function does not have.