React Query is now written in TypeScript to make sure the library and your projects are type-safe!
React Query is currently typed with an external type definition file, which unfortunately often gets out of sync with the actual code.
This is one of the reasons why the library has been migrated to TypeScript.
But before exposing the new types, we first want to get your feedback on it!
Install the tsnext
tag to get the latest React Query with the new types:
npm install react-query@tsnext --save
data
and error
properties.The latest TanStack news, articles, and resources, sent to your inbox.