Files
2026-05-27 23:29:53 +01:00

1.3 KiB

Tasks — events v1.1.0 port

Core (@suaveplan/events)

  • Add bufferSize option to EventBusOptions — replay buffered events to late subscribers
  • Add wildcard option to EventBusOptions — pattern matching on event names
  • Add iter(type, signal?) — async iteration over events
  • Add prepend(type, listener) — prepend listener to dispatch queue
  • Add listeners(type) — return copy of exact-match listeners
  • Add listenerCount(type) — return exact-match listener count
  • Add offAll(type?) — remove all listeners for a type or everything
  • Fix once() → off() round-trip via WeakMap tracking
  • Add concurrency option to EmitAsyncOptions (sequential / parallel / allSettled)
  • Add maxListeners + errorSink to EventBusOptions
  • Add EVENTS.LISTENER.MAX_EXCEEDED error code
  • Implement Symbol.dispose on EventBus and Unsubscribe
  • Update event-bus.md documentation
  • Add tests for all new capabilities
  • Type-check and test downstream dependents
  • Update openspec/specs/events/spec.md

Acceptance

  • 100% test coverage maintained on @suaveplan/events
  • All downstream packages that import @suaveplan/events compile and test green
  • No breaking changes to existing public API