UNPKG

@boost/event

Version:

An event system with multiple emitter patterns.

33 lines (21 loc) 752 B
# Events - Boost ![build status](https://img.shields.io/github/actions/workflow/status/milesj/boost/build.yml) ![npm version](https://img.shields.io/npm/v/@boost/event) A strict event system with multiple emitter patterns. ```ts import { Event } from '@boost/event'; const event = new Event<[string, number]>('name'); event.listen(listener); event.emit(['abc', 123]); ``` ## Features - Isolated event instances for proper type-safety. - Supports 4 event types: standard, bail, concurrent, and waterfall. - Listener scopes for targeted emits. ## Installation ``` yarn add @boost/event ``` ## Documentation - [https://boostlib.dev/docs/event](https://boostlib.dev/docs/event) - [https://boostlib.dev/api/event](https://boostlib.dev/api/event)