Installation
npm install --save @types/refresh-fetch
Summary
This package contains type definitions for refresh-fetch (https://github.com/vlki/refresh-fetch).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/refresh-fetch.
index.d.ts
export function configureRefreshFetch<T>(
configuration: {
fetch: T;
refreshToken: () => Promise<void>;
shouldRefreshToken: (error: any) => boolean;
},
): T;
/* eslint-disable-next-line @definitelytyped/no-unnecessary-generics */
export function fetchJSON<ResponseBody>(url: string | Request | URL, options?: RequestInit): Promise<{
body: ResponseBody;
response: Response;
}>;
Additional Details
- Last updated: Tue, 07 Nov 2023 15:11:36 GMT
- Dependencies: none
Credits
These definitions were written by Alex Lisenkov, and Pieter Braam.