metz-sh / simulacrum

Code-playground to visualise complex engineering flows.
https://metz.sh
Apache License 2.0
400 stars 28 forks source link

Add support for type safe event emitters #3

Closed iostreamer-X closed 3 months ago

iostreamer-X commented 3 months ago

This closes #1 adds the ability to:

Entities Added

Channel

It has a slug, which marks its unique identifier. It maintains a Set of listeners and manages adding, deleting and most importantly sending data.

ChannelEmitter

This is the interface that's exposed to users to help them create channels and emit events

Update to standard Library

Added std.createChannelEmitter and std.registerChannelListener