import { default } from "https://deno.land/x/subscription@2.0.1/mod.ts";
A subscribable event.
Properties
private
readonly
_subscriptions: Map<Subscription<T>, boolean>The listeners that are currently subscribed to the event.
Methods
subscribe(...listeners: Subscription<T>[]): this
Subscribe to the event.
subscribeOnce(...listeners: Subscription<T>[]): this
Subscribe to the event once.
unsubscribe(...listeners: Subscription<T>[]): this
Unsubscribe to the event.