Yielded value type.
Return value type.
Thrown error type (default: unknown).
An AsyncChannel.
Each call to [Symbol.asyncIterator]() returns a fresh iterator starting
from the first buffered value. Calling result() multiple times returns
the same promise without affecting iteration.
A rejected result is internally observed, so iteration-only consumers do not
cause an unhandled result rejection; callers of result() still receive it.
Subscribers run synchronously. If one throws, it is detached, all other pending consumers are notified, and the first callback exception is rethrown to the producer. Callback exceptions do not change the channel's result, including on completion or error. Exceptions during buffered replay instead propagate from the subscription call.
Buffered events are retained for the lifetime of the channel; memory grows with the number of events. Stopping one iterator does not stop the producer.
Creates an async channel that buffers values and replays them to each iterator.