React · Middle · Question 38 of 75

What is RTK Query?

Explanation

createApi describes endpoints, and the library generates hooks like useGetPostsQuery and manages caching, deduplication, refetching and tag-based invalidation. It solves the same problems as TanStack Query but is built into the Redux infrastructure. It works with GraphQL too, but it isn't a server plugin.

Further reading

Problem with a question

React · Middle · question 38

Test yourself

Take the React · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz