React Query Configuration Error
Author: rayhankinanCreated Jul 2, 2025Updated Jul 2, 2025
I think both of these lines have mismatched types:
Should both of these lines be defined as the following:
queryConfig?: InfiniteQueryConfig<typeof getInfiniteCommentsQueryOptions>With InfiniteQueryConfig:
type InfiniteQueryConfig<T extends (...args: any[]) => any> = Omit<
ReturnType<T>,
"queryKey" | "queryFn" | "getNextPageParam" | "initialPageParam"
>;Correct me if I'm wrong though
Source: alan2207/bulletproof-react