Documentation
Interfaces
common.Sink

Interface: Sink<T>

common.Sink

A representation of any set of values over any amount of time.

Type parameters

NameType
Tunknown

Methods

complete

complete(): void

The sink has completed. This function “closes” the sink.

Returns

void

Defined in

src/common.ts:77


error

error(error): void

An error that has occured. Calling this function “closes” the sink. Besides the errors being Error and readonly GraphQLError[], it can also be a CloseEvent, but to avoid bundling DOM typings because the client can run in Node env too, you should assert the close event type during implementation.

Parameters

NameType
errorunknown

Returns

void

Defined in

src/common.ts:75


next

next(value): void

Next value arriving.

Parameters

NameType
valueT

Returns

void

Defined in

src/common.ts:67