CacheValueType
Import
import { CacheValueType } from "@hyper-fetch/core"
Source
Package
Preview
type CacheValueType<Response,Error,Adapter> = ResponseType<Response, Error, Adapter> & ResponseDetailsType & { cacheKey: string; cacheTime: number; cached: boolean; hydrated?: boolean; staleTime: number; version: string };
Structure
CacheValueType
| Name | Type | Description |
|---|---|---|
| data | | |
| error | | |
| extra | | |
| requestTimestamp | | |
| responseTimestamp | | |
| status | | |
| success | | |
| addedTimestamp | | When added to dispatcher's queue (pre-middleware which could take time) |
| isCanceled | | If request was canceled |
| isOffline | | If error from offline status |
| requestTimestamp | | When adapter triggers request (after all middlewares) |
| responseTimestamp | | When we receive response |
| retries | | If it's retry request we can see which attempt is it |
| triggerTimestamp | | When request is picked from queue and started to be sent |
| cacheKey | | |
| cacheTime | | |
| cached | | |
| hydrated | | |
| staleTime | | |
| version | |