Type alias Channel<T>

Channel<T>: PromiseLike<T> & AsyncIterable<T> & {
    end: ((value: T) => void);
    put: ((value: T) => void);
    take: (() => Promise<T>);
}

Async Channel ala Go

Generic

T - type of values in the channel

Type Parameters

  • T

Generated using TypeDoc