Skip to content

Commit 308e5a9

Browse files
authored
Add typing support for initialData
This PR is to fix the following bug 🐛 found when using the `useQuery` method : `Argument of type '{ initialData: string; }' is not assignable to parameter of type '{ cacheTime?: number | undefined; staleTime?: number | undefined; ssr?: boolean | undefined; client?: ApiClient | undefined; }`
1 parent 53c050e commit 308e5a9

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

types/index.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ declare module 'jsonapi-react' {
102102
staleTime?: number
103103
ssr?: boolean
104104
client?: ApiClient
105+
initialData?: TData
105106
}
106107
): IResult<TData>
107108
}

0 commit comments

Comments
 (0)