Back to Apollo Client

Api Report Link Context.Api

.api-reports/api-report-link_context.api.md

3.14.11.4 KB
Original Source

API Report File for "@apollo/client"

Do not edit this file. It is a report generated by API Extractor.

ts

import { ApolloLink } from '@apollo/client/link';

// @public @deprecated (undocumented)
export function setContext(setter: SetContextLink.LegacyContextSetter): SetContextLink;

// @public (undocumented)
export namespace SetContextLink {
    export type ContextSetter = (prevContext: Readonly<ApolloLink.OperationContext>, operation: SetContextLink.SetContextOperation) => Promise<Partial<ApolloLink.OperationContext>> | Partial<ApolloLink.OperationContext>;
    // @deprecated (undocumented)
    export type LegacyContextSetter = (operation: SetContextLink.SetContextOperation, prevContext: Readonly<ApolloLink.OperationContext>) => Promise<Partial<ApolloLink.OperationContext>> | Partial<ApolloLink.OperationContext>;
    // (undocumented)
    export namespace SetContextLinkDocumentationTypes {
        export function ContextSetter(prevContext: Readonly<ApolloLink.OperationContext>, operation: SetContextLink.SetContextOperation): Promise<Partial<ApolloLink.OperationContext>> | Partial<ApolloLink.OperationContext>;
    }
    export type SetContextOperation = Omit<ApolloLink.Operation, "getContext" | "setContext">;
}

// @public
export class SetContextLink extends ApolloLink {
    constructor(setter: SetContextLink.ContextSetter);
}

// (No @packageDocumentation comment for this package)