I have a RTK Query endpoint called getUsers which fetches user data in a batch for multiple user ids, provided as an array.
Now I am concerned about caching behaviour. Is there a way I can make RTK Query fetch user data for the missing users only?
for ex
const { data } = useGetUsersQuery([1, 2, 3])
should fetch users 1, 2 and 3
now, afterwards
const { data } = useGetUsersQuery([2, 3, 4, 5])
should treat this api as fetch users 4 and 5, merge with existing data for 2 and 3. And return the entire data?