subscribableevent
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

SubscribableEvent

GitHub license npm version Build Status David David

A simple strongly-typed pub/sub/fire eventing system

Basic Example

const event = new SubscribableEvent<(payload: string) => void>(); 
 
event.subscribe((payload: string) => {
    console.log(payload);
});
 
event.fire('Payload Params');

Contributing

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.1
    1,026
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.1
    1,026
  • 1.0.0
    3
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i subscribableevent

Weekly Downloads

842

Version

1.0.1

License

MIT

Unpacked Size

17.6 kB

Total Files

15

Last publish

Collaborators

  • berickson1
  • deregtd