View on GitHub


Cross-browser event handling system

download .ZIPdownload .TGZ


Light-weight cross-browser event handling system.


evento provides three functions - add, remove, trigger - which can be used to register, remove, or fire event handlers to/attached to the EventTarget. The EventTarget must be an instance of Element, Window or Document.

If you don't know what they do, go learn some JavaScript.

.add() - Register the handler to the EventTarget whenever the event is fired.

evento.add(EventTarget, event, handler);

.remove() - Remove the handler registered to the EventTarget and prevent it from being called on event.

evento.remove(EventTarget, event, handler);

.trigger() - Trigger an event on the EventTarget. Note: This will call all handlers that have been registered to be called on event for that EventTarget.

evento.trigger(EventTarget, event);