Type Parameters
- Data = any
- Error = any
- SWRKey extends Key = Key
SWRHook< Data = any, Error = any, SWRKey extends Key = StrictKey, SWROptions extends undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>> = | undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>>,>( key: SWRKey,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWRKey extends Key = StrictKey, SWROptions extends undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>> = | undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>>,>( key: SWRKey, fetcher: null | Fetcher<Data, SWRKey>,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWRKey extends Key = StrictKey, SWROptions extends undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>> = | undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>>,>( key: SWRKey, config: SWRConfigurationWithOptionalFallback<SWROptions>,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWRKey extends Key = StrictKey, SWROptions extends undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>> = | undefined | SWRConfiguration<Data, Error, Fetcher<Data, SWRKey>>,>( key: SWRKey, fetcher: null | Fetcher<Data, SWRKey>, config: SWRConfigurationWithOptionalFallback<SWROptions>,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWROptions extends undefined | SWRConfiguration<Data, Error, BareFetcher<Data>> = | undefined | SWRConfiguration<Data, Error, BareFetcher<Data>>,>( key: Key,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWROptions extends undefined | SWRConfiguration<Data, Error, BareFetcher<Data>> = | undefined | SWRConfiguration<Data, Error, BareFetcher<Data>>,>( key: Key, fetcher: null | BareFetcher<Data>,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWROptions extends undefined | SWRConfiguration<Data, Error, BareFetcher<Data>> = | undefined | SWRConfiguration<Data, Error, BareFetcher<Data>>,>( key: Key, config: SWRConfigurationWithOptionalFallback<SWROptions>,): SWRResponse<Data, Error, SWROptions> SWRHook< Data = any, Error = any, SWROptions extends undefined | SWRConfiguration<Data, Error, BareFetcher<Data>> = | undefined | SWRConfiguration<Data, Error, BareFetcher<Data>>,>( key: Key, fetcher: null | BareFetcher<Data>, config: SWRConfigurationWithOptionalFallback<SWROptions>,): SWRResponse<Data, Error, SWROptions>
Example