You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But it looks like this definition is missing from type definition:
import{CLOSED}from"./mod.js";/** * An asynchronous channel that can be used to communicate between async functions. * * Note that this is Multi-Producer Single-Consumer (MPSC) channel, meaning that multiple async functions can send values to the channel, * but only one async function can receive values from the channel. */exportdeclareclassUnboundedChannel<T>{/** Constructs a new channel. */constructor();/** Sends a value to the channel. */send(value: T): void;/** Closes the channel. */close(): void;/** Returns whether the channel is closed. */getisClosed(): boolean;/** Receives a value from the channel. If the channel is closed, returns {@link CLOSED}. */receive(): Promise<T|typeofCLOSED>;/** Receives a value from the channel. If the channel is closed, throws a {@link ClosedChannelError}. */receiveOrThrow(): Promise<T>;/** Peeks at the next value in the channel. If the channel is closed, returns {@link CLOSED}. */peek(): T|undefined|typeofCLOSED;/** Peeks at the next value in the channel. If the channel is closed, throws a {@link ClosedChannelError}. */peekOrThrow(): T|undefined;/** Returns the number of values in the channel. */getlength(): number;/** Returns whether the channel is empty. */getisEmpty(): boolean;}//# sourceMappingURL=mpsc.d.ts.map
The text was updated successfully, but these errors were encountered:
sevenc-nanashi
changed the title
Symbol.asyncIterator is missing from type definition of npm layer
bug: Symbol.asyncIterator is missing from type definition of npm layer
Feb 2, 2025
I have a library whose class has
[Symbol.asyncIterator]
method: https://jsr.io/@sevenc-nanashi/async-channel/doc/~/UnboundedChannel#method_symbol_asynciterator_0But it looks like this definition is missing from type definition:
The text was updated successfully, but these errors were encountered: