Skip to main content
Module

x/disc/src/typings/TypedEmitter.ts

Low level Discord API wrapper
Latest
import * as disc from "https://deno.land/x/disc@0.3.0-alpha/src/typings/TypedEmitter.ts";

Functions

Returns an AsyncIterator that iterates eventName events. It will throw if the TypedEmitter emits 'error'. It removes all listeners when exiting the loop. The value returned by each iteration is an array composed of the emitted event arguments.

Creates a Promise that is fulfilled when the TypedEmitter emits the given event or that is rejected when the TypedEmitter emits 'error'. The Promise will resolve with an array of all the arguments emitted to the given event.