ractive.on()
edit this pageSubscribe to events.
ractive.on( eventName, handler )
Returns an
Object
with acancel
method, which removes the handler.eventName
String
The name of the event to subscribe to
handler
Function
The function that will be called, with
ractive
asthis
. The arguments depend on the eventractive.on( obj )
Returns an
Object
with acancel
method, which removes all handlers in the passed-inobj
.obj
Object
An object with keys named for each event to subscribe to. The value at each key is the handler function for that event.