Skip to content

Commit

Permalink
fix: ts definitions for makeUseAxios
Browse files Browse the repository at this point in the history
  • Loading branch information
simoneb committed Dec 6, 2019
1 parent 3f83b19 commit 13b20cc
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions src/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ interface ConfigureOptions {
cache?: LRUCache<any, any>
}

interface UseAxios<T = any> {
(config: AxiosRequestConfig | string, options?: Options): [
interface UseAxios {
<T = any>(config: AxiosRequestConfig | string, options?: Options): [
ResponseValues<T>,
(config?: AxiosRequestConfig, options?: RefetchOptions) => AxiosPromise<T>
]
Expand All @@ -49,14 +49,6 @@ declare const defaultUseAxios: UseAxios

export default defaultUseAxios

export function useAxios<T = any>(
config: AxiosRequestConfig | string,
options?: Options
): [
ResponseValues<T>,
(config?: AxiosRequestConfig, options?: RefetchOptions) => AxiosPromise<T>
]

export function loadCache(data: any[]): void
export function serializeCache(): Promise<any[]>

Expand Down

0 comments on commit 13b20cc

Please sign in to comment.