@@ -17,13 +17,15 @@ import type { GraphQLErrorExtensions } from 'graphql';
1717import type { GraphQLFormattedError } from ' graphql' ;
1818import type { InlineFragmentNode } from ' graphql' ;
1919import { InvariantError } from ' ts-invariant' ;
20- import { Observable } from ' zen-observable-ts ' ;
21- import type { Subscription as ObservableSubscription } from ' zen-observable-ts ' ;
22- import type { Observer } from ' zen-observable-ts ' ;
20+ import { Observable } from ' rxjs ' ;
21+ import type { Observer } from ' rxjs ' ;
22+ import type { OperatorFunction } from ' rxjs ' ;
2323import { resetCaches } from ' graphql-tag' ;
2424import type { SelectionSetNode } from ' graphql' ;
2525import { setVerbosity as setLogVerbosity } from ' ts-invariant' ;
26- import type { Subscriber } from ' zen-observable-ts' ;
26+ import type { Subscribable } from ' rxjs' ;
27+ import type { Subscriber } from ' rxjs' ;
28+ import type { Subscription } from ' rxjs' ;
2729import { Trie } from ' @wry/trie' ;
2830import { TypedDocumentNode } from ' @graphql-typed-document-node/core' ;
2931
@@ -236,7 +238,7 @@ export class ApolloLink {
236238 // @internal
237239 readonly left? : ApolloLink ;
238240 // (undocumented)
239- protected onError(error : any , observer ? : Observer <FetchResult >): false | void ;
241+ protected onError(error : any , observer ? : Subscriber <FetchResult >): false | void ;
240242 // (undocumented)
241243 request(operation : Operation , forward ? : NextLink ): Observable <FetchResult > | null ;
242244 // @internal
@@ -444,30 +446,6 @@ type CombineIntersection<T> = Exclude<T, {
444446 __typename? : string ;
445447}>>;
446448
447- // @public (undocumented)
448- class Concast <T > extends Observable <T > {
449- // Warning: (ae-forgotten-export) The symbol "MaybeAsync" needs to be exported by the entry point index.d.ts
450- // Warning: (ae-forgotten-export) The symbol "ConcastSourcesIterable" needs to be exported by the entry point index.d.ts
451- constructor (sources : MaybeAsync <ConcastSourcesIterable <T >> | Subscriber <T >);
452- // (undocumented)
453- addObserver(observer : Observer <T >): void ;
454- // Warning: (ae-forgotten-export) The symbol "NextResultListener" needs to be exported by the entry point index.d.ts
455- //
456- // (undocumented)
457- beforeNext(callback : NextResultListener ): void ;
458- // (undocumented)
459- cancel: (reason : any ) => void ;
460- // (undocumented)
461- readonly promise: Promise <T | undefined >;
462- // (undocumented)
463- removeObserver(observer : Observer <T >): void ;
464- }
465-
466- // Warning: (ae-forgotten-export) The symbol "Source" needs to be exported by the entry point index.d.ts
467- //
468- // @public (undocumented)
469- type ConcastSourcesIterable <T > = Iterable <Source <T >>;
470-
471449// @public (undocumented)
472450export const concat: typeof ApolloLink .concat ;
473451
@@ -976,12 +954,6 @@ TData
976954// @public (undocumented)
977955export const from: typeof ApolloLink .from ;
978956
979- // @public (undocumented)
980- export function fromError<T >(errorValue : any ): Observable <T >;
981-
982- // @public (undocumented)
983- export function fromPromise<T >(promise : Promise <T >): Observable <T >;
984-
985957// @internal
986958const getApolloCacheMemoryInternals: (() => {
987959 cache: {
@@ -1404,9 +1376,6 @@ interface MaskOperationOptions<TData> {
14041376 id: string ;
14051377}
14061378
1407- // @public (undocumented)
1408- type MaybeAsync <T > = T | PromiseLike <T >;
1409-
14101379// Warning: (ae-forgotten-export) The symbol "RemoveMaskedMarker" needs to be exported by the entry point index.d.ts
14111380//
14121381// @public
@@ -1623,9 +1592,6 @@ interface NextFetchPolicyContext<TData, TVariables extends OperationVariables> {
16231592// @public (undocumented)
16241593export type NextLink = (operation : Operation ) => Observable <FetchResult >;
16251594
1626- // @public (undocumented)
1627- type NextResultListener = (method : " next" | " error" | " complete" , arg ? : any ) => any ;
1628-
16291595// @public
16301596type NoInfer_2 <T > = [T ][T extends any ? 0 : never ];
16311597
@@ -1672,10 +1638,8 @@ export interface NormalizedCacheObject {
16721638 };
16731639}
16741640
1675- export { Observable }
1676-
16771641// @public (undocumented)
1678- export class ObservableQuery <TData = any , TVariables extends OperationVariables = OperationVariables > extends Observable <ApolloQueryResult <MaybeMasked <TData >>> {
1642+ export class ObservableQuery <TData = any , TVariables extends OperationVariables = OperationVariables > implements Subscribable <ApolloQueryResult <MaybeMasked <TData >>> {
16791643 constructor ({ queryManager , queryInfo , options , }: {
16801644 queryManager: QueryManager <any >;
16811645 queryInfo: QueryInfo ;
@@ -1700,6 +1664,28 @@ export class ObservableQuery<TData = any, TVariables extends OperationVariables
17001664 // (undocumented)
17011665 readonly options: WatchQueryOptions <TVariables , TData >;
17021666 // (undocumented)
1667+ pipe(): Observable <ApolloQueryResult <MaybeMasked <TData >>>;
1668+ // (undocumented)
1669+ pipe<A >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >): Observable <A >;
1670+ // (undocumented)
1671+ pipe<A , B >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >): Observable <B >;
1672+ // (undocumented)
1673+ pipe<A , B , C >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >): Observable <C >;
1674+ // (undocumented)
1675+ pipe<A , B , C , D >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >): Observable <D >;
1676+ // (undocumented)
1677+ pipe<A , B , C , D , E >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >, op5 : OperatorFunction <D , E >): Observable <E >;
1678+ // (undocumented)
1679+ pipe<A , B , C , D , E , F >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >, op5 : OperatorFunction <D , E >, op6 : OperatorFunction <E , F >): Observable <F >;
1680+ // (undocumented)
1681+ pipe<A , B , C , D , E , F , G >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >, op5 : OperatorFunction <D , E >, op6 : OperatorFunction <E , F >, op7 : OperatorFunction <F , G >): Observable <G >;
1682+ // (undocumented)
1683+ pipe<A , B , C , D , E , F , G , H >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >, op5 : OperatorFunction <D , E >, op6 : OperatorFunction <E , F >, op7 : OperatorFunction <F , G >, op8 : OperatorFunction <G , H >): Observable <H >;
1684+ // (undocumented)
1685+ pipe<A , B , C , D , E , F , G , H , I >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >, op5 : OperatorFunction <D , E >, op6 : OperatorFunction <E , F >, op7 : OperatorFunction <F , G >, op8 : OperatorFunction <G , H >, op9 : OperatorFunction <H , I >): Observable <I >;
1686+ // (undocumented)
1687+ pipe<A , B , C , D , E , F , G , H , I >(op1 : OperatorFunction <ApolloQueryResult <MaybeMasked <TData >>, A >, op2 : OperatorFunction <A , B >, op3 : OperatorFunction <B , C >, op4 : OperatorFunction <C , D >, op5 : OperatorFunction <D , E >, op6 : OperatorFunction <E , F >, op7 : OperatorFunction <F , G >, op8 : OperatorFunction <G , H >, op9 : OperatorFunction <H , I >, ... operations : OperatorFunction <any , any >[]): Observable <unknown >;
1688+ // (undocumented)
17031689 get query(): TypedDocumentNode <TData , TVariables >;
17041690 // (undocumented)
17051691 readonly queryId: string ;
@@ -1708,21 +1694,13 @@ export class ObservableQuery<TData = any, TVariables extends OperationVariables
17081694 refetch(variables ? : Partial <TVariables >): Promise <ApolloQueryResult <MaybeMasked <TData >>>;
17091695 // (undocumented)
17101696 reobserve(newOptions ? : Partial <WatchQueryOptions <TVariables , TData >>, newNetworkStatus ? : NetworkStatus ): Promise <ApolloQueryResult <MaybeMasked <TData >>>;
1711- // Warning: (ae-forgotten-export) The symbol "Concast" needs to be exported by the entry point index.d.ts
1712- //
1713- // (undocumented)
1714- reobserveAsConcast(newOptions ? : Partial <WatchQueryOptions <TVariables , TData >>, newNetworkStatus ? : NetworkStatus ): Concast <ApolloQueryResult <TData >>;
17151697 // @internal (undocumented)
17161698 resetDiff(): void ;
17171699 // (undocumented)
17181700 resetLastResults(): void ;
17191701 // (undocumented)
17201702 resetQueryStoreErrors(): void ;
17211703 // (undocumented)
1722- resubscribeAfterError(onNext : (value : ApolloQueryResult <MaybeMasked <TData >>) => void , onError ? : (error : any ) => void , onComplete ? : () => void ): ObservableSubscription ;
1723- // (undocumented)
1724- resubscribeAfterError(observer : Observer <ApolloQueryResult <TData >>): ObservableSubscription ;
1725- // (undocumented)
17261704 result(): Promise <ApolloQueryResult <MaybeMasked <TData >>>;
17271705 // (undocumented)
17281706 setOptions(newOptions : Partial <WatchQueryOptions <TVariables , TData >>): Promise <ApolloQueryResult <MaybeMasked <TData >>>;
@@ -1731,15 +1709,13 @@ export class ObservableQuery<TData = any, TVariables extends OperationVariables
17311709 silentSetOptions(newOptions : Partial <WatchQueryOptions <TVariables , TData >>): void ;
17321710 startPolling(pollInterval : number ): void ;
17331711 stopPolling(): void ;
1712+ // (undocumented)
1713+ subscribe(observer : Partial <Observer <ApolloQueryResult <MaybeMasked <TData >>>> | ((value : ApolloQueryResult <MaybeMasked <TData >>) => void )): Subscription ;
17341714 subscribeToMore<TSubscriptionData = TData , TSubscriptionVariables extends OperationVariables = TVariables >(options : SubscribeToMoreOptions <TData , TSubscriptionVariables , TSubscriptionData , TVariables >): () => void ;
17351715 updateQuery(mapFn : UpdateQueryMapFn <TData , TVariables >): void ;
17361716 get variables(): TVariables | undefined ;
17371717}
17381718
1739- export { ObservableSubscription }
1740-
1741- export { Observer }
1742-
17431719// @public (undocumented)
17441720export type OnQueryUpdated <TResult > = (observableQuery : ObservableQuery <any >, diff : Cache_2 .DiffResult <any >, lastDiff : Cache_2 .DiffResult <any > | undefined ) => boolean | TResult ;
17451721
@@ -2281,9 +2257,6 @@ export interface SingleExecutionResult<TData = Record<string, any>, TContext = D
22812257 extensions? : TExtensions ;
22822258}
22832259
2284- // @public (undocumented)
2285- type Source <T > = MaybeAsync <Observable <T >>;
2286-
22872260// @public (undocumented)
22882261export const split: typeof ApolloLink .split ;
22892262
@@ -2365,9 +2338,6 @@ type takeOneFromUnion<T> = unionToIntersection<T extends T ? (x: T) => 0 : never
23652338// @public (undocumented)
23662339export const throwServerError: (response : Response , result : any , message : string ) => never ;
23672340
2368- // @public (undocumented)
2369- export function toPromise<R >(observable : Observable <R >): Promise <R >;
2370-
23712341// @public (undocumented)
23722342type ToReferenceFunction = (objOrIdOrRef : StoreObject | string | Reference , mergeIntoStore ? : boolean ) => Reference | undefined ;
23732343
@@ -2535,10 +2505,10 @@ interface WriteContext extends ReadMergeModifyContext {
25352505// src/cache/inmemory/policies.ts:162:3 - (ae-forgotten-export) The symbol "KeySpecifier" needs to be exported by the entry point index.d.ts
25362506// src/cache/inmemory/policies.ts:162:3 - (ae-forgotten-export) The symbol "KeyArgsFunction" needs to be exported by the entry point index.d.ts
25372507// src/cache/inmemory/types.ts:139:3 - (ae-forgotten-export) The symbol "KeyFieldsFunction" needs to be exported by the entry point index.d.ts
2538- // src/core/ObservableQuery.ts:118 :5 - (ae-forgotten-export) The symbol "QueryManager" needs to be exported by the entry point index.d.ts
2539- // src/core/ObservableQuery.ts:119 :5 - (ae-forgotten-export) The symbol "QueryInfo" needs to be exported by the entry point index.d.ts
2540- // src/core/QueryManager.ts:159 :5 - (ae-forgotten-export) The symbol "MutationStoreValue" needs to be exported by the entry point index.d.ts
2541- // src/core/QueryManager.ts:414 :7 - (ae-forgotten-export) The symbol "UpdateQueries" needs to be exported by the entry point index.d.ts
2508+ // src/core/ObservableQuery.ts:117 :5 - (ae-forgotten-export) The symbol "QueryManager" needs to be exported by the entry point index.d.ts
2509+ // src/core/ObservableQuery.ts:118 :5 - (ae-forgotten-export) The symbol "QueryInfo" needs to be exported by the entry point index.d.ts
2510+ // src/core/QueryManager.ts:170 :5 - (ae-forgotten-export) The symbol "MutationStoreValue" needs to be exported by the entry point index.d.ts
2511+ // src/core/QueryManager.ts:428 :7 - (ae-forgotten-export) The symbol "UpdateQueries" needs to be exported by the entry point index.d.ts
25422512// src/link/http/selectHttpOptionsAndBody.ts:128:1 - (ae-forgotten-export) The symbol "HttpQueryOptions" needs to be exported by the entry point index.d.ts
25432513
25442514// (No @packageDocumentation comment for this package)
0 commit comments