apollo-angular
Version:
Use your GraphQL data in your Angular app, with the Apollo Client
19 lines (18 loc) • 687 B
TypeScript
import { FormattedExecutionResult, GraphQLError } from 'graphql';
import { Observer } from 'rxjs';
import { ApolloError, FetchResult, Operation as LinkOperation } from '@apollo/client/core';
export type Operation = LinkOperation & {
clientName: string;
};
export declare class TestOperation<T = {
[key: string]: any;
}> {
readonly operation: Operation;
private readonly observer;
constructor(operation: Operation, observer: Observer<FetchResult<T>>);
flush(result: FormattedExecutionResult<T> | ApolloError): void;
complete(): void;
flushData(data: T | null): void;
networkError(error: Error): void;
graphqlErrors(errors: GraphQLError[]): void;
}