-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
We might need something like:
import wtf.mizu.kawa.OptimizedBus
fun main() {
val bus = OptimizedBus()
bus.addListener {
on<String> {
println(it)
}
}
val event = "foobar123"
bus.publish(event)
}and
import wtf.mizu.kawa.OptimizedBus
fun main() {
val bus = OptimizedBus()
bus.addListener<String> {
println(it)
}
val event = "foobar123"
bus.publish(event)
}or name the function whatever we want, like buildListener as @xtrm-en told me but that wouldn't really make sense as we're not only building it but also adding it directly.