Skip to content

Commit

Permalink
fix(trpc-react-query): extend QueryObserverOptions
Browse files Browse the repository at this point in the history
Signed-off-by: Marc MacLeod <847542+marbemac@users.noreply.github.com>
  • Loading branch information
marbemac committed Dec 29, 2023
1 parent 6b6d842 commit a4ebe64
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/tough-turtles-divide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@ssrx/trpc-react-query': patch
---

Extend QueryObserverOptions in useQuery
4 changes: 2 additions & 2 deletions packages/trpc-react-query/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import type {
MutationOptions,
QueryClient,
QueryKey,
QueryOptions,
QueryObserverOptions,
UseInfiniteQueryOptions,
} from '@tanstack/react-query';
import type { TRPCRequestOptions, TRPCUntypedClient } from '@trpc/client';
Expand Down Expand Up @@ -57,7 +57,7 @@ export type CreateQueryOptions<
TError = unknown,
TData = TQueryFnData,
TQueryKey extends QueryKey = QueryKey,
> = OmitUseless<QueryOptions<TQueryFnData, TError, TData, TQueryKey>>;
> = OmitUseless<QueryObserverOptions<TQueryFnData, TError, TData, TQueryKey>>;

export type CreateInfiniteQueryOptions<
TQueryFnData = unknown,
Expand Down

0 comments on commit a4ebe64

Please sign in to comment.