UNPKG

relay-link-batch-http

Version:

Batch HTTP transport layer for Relay

18 lines 707 B
import { Operation, OperationResponse, RelayLink } from 'relay-link'; import { HttpOptions } from 'relay-link-http-common'; import { Observable } from 'relay-runtime'; export declare namespace BatchHttpLink { interface Options extends HttpOptions { batchMax?: number; batchInterval?: number; batchKey?: (operation: Operation) => string; } } export declare class BatchHttpLink extends RelayLink { private readonly batchInterval; private readonly batchMax; private readonly batcher; constructor(fetchParams?: BatchHttpLink.Options); request(operation: Operation): Observable<OperationResponse>; } //# sourceMappingURL=batchHttpLink.d.ts.map