@@ -49,18 +49,20 @@ import type {
4949
5050const { assign, hasOwnProperty } = Object ;
5151
52- export interface FetchMoreOptions <
52+ export type FetchMoreOptions <
5353 TData = unknown ,
54- TVariables = OperationVariables ,
55- > {
54+ TVariables extends OperationVariables = OperationVariables ,
55+ TFetchData = TData ,
56+ TFetchVars extends OperationVariables = TVariables ,
57+ > = FetchMoreQueryOptions < TFetchVars , TFetchData > & {
5658 updateQuery ?: (
57- previousQueryResult : TData ,
59+ previousQueryResult : Unmasked < TData > ,
5860 options : {
59- fetchMoreResult ?: TData ;
60- variables ?: TVariables ;
61+ fetchMoreResult : Unmasked < TFetchData > ;
62+ variables : TFetchVars ;
6163 }
62- ) => TData ;
63- }
64+ ) => Unmasked < TData > ;
65+ } ;
6466
6567interface TrackedOperation {
6668 /**
@@ -714,15 +716,9 @@ Did you mean to call refetch(variables) instead of refetch({ variables })?`,
714716 context,
715717 errorPolicy,
716718 updateQuery,
717- } : FetchMoreQueryOptions < TFetchVars , TFetchData > & {
718- updateQuery ?: (
719- previousQueryResult : Unmasked < TData > ,
720- options : {
721- fetchMoreResult : Unmasked < TFetchData > ;
722- variables : TFetchVars ;
723- }
724- ) => Unmasked < TData > ;
725- } ) : Promise < QueryResult < TFetchData > > {
719+ } : FetchMoreOptions < TData , TVariables , TFetchData , TFetchVars > ) : Promise <
720+ QueryResult < TFetchData >
721+ > {
726722 const combinedOptions = {
727723 ...compact (
728724 this . options ,
0 commit comments