xtify reactor onBeforeMessage is not working -
i using reactor http://getreactor.xtify.com/ on backbone application , trying build custom inbox box. use auto-run="false" config param. define function onbeforemessage
reactor.onbeforemessage(function(message){ console.log('new message'); });
this function of times been called other not. first question why onbeforemessage triggered although specify auto-run="false" ? second question why onbeforemessage not triggered ?
you'll need use:
data-auto-run="false"
instead of:
auto-run="false"
the 'data-' prefix the html5 way store metadata on html element.
you can see js fiddle in-depth explanation of how implement custom inbox here:
note function register reactor.onbeforemessage() accepts list of messages have been triggered rather single message. can see more documentation here:
Comments
Post a Comment