abon
Version:
Flexible state management for React 🚀
9 lines (8 loc) • 413 B
TypeScript
import { ReadonlyAbonEvent } from "./readonly-abon-event";
/** Notify and subscribe to events and payloads. */
export declare class AbonEvent<E = undefined, P = undefined> extends ReadonlyAbonEvent<E, P> {
notify(event: E): void;
notify(event: E, payload: P): void;
notify(event: E, payloads: P[]): void;
static use<E = undefined, P = undefined>(deps?: readonly any[]): AbonEvent<E, P>;
}