aribouius / jsonapi-react

A minimal JSON:API client and React hooks for fetching, updating, and caching remote data.
MIT License
149 stars 28 forks source link

Add typing support for initialData #34

Closed Steffi3rd closed 3 years ago

Steffi3rd commented 3 years ago

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; }