Allow setting event type when posting a message
codebrew opened this issue · comments
Code Brew Studios commented
Right now all events being dispatched just have an event type of "message". It would be great if you could optionally control the type when posting a message. This would with creating multiple handlers that just care about specific types of messages.
something like
postMessage(message, [options])
possible options {type: "closeFrame"}
Deleted user commented
Payload now supports full javascript objects. You can easily add a type attribute and filter against that in your listener.