rniemeyer / knockout-postbox

A small library that uses Knockout's native pub/sub capabilities to facilitate decoupled communication between separate view models or components.
MIT License
350 stars 55 forks source link

Is possible to send functions instead of data using postbox? #44

Closed Tecayehuatl closed 7 years ago

Tecayehuatl commented 7 years ago

I know how to send data from a publish to a subscriber but I would like to send not only data, actually I would like to send a function, is this possible?

rniemeyer commented 7 years ago

@Tecayehuatl - Hope you figured out your scenario. While it is not the normal scenario, you should be fine with publishing functions. The only piece that won't work is the logic that compares the latest published value before publishing the same value again.