DefinitelyTyped/ftdomdelegate/ftdomdelegate-tests.ts
2014-01-24 09:42:26 +01:00

15 lines
380 B
TypeScript

/// <reference path="ftdomdelegate.d.ts" />
window.addEventListener('load', function() {
var delegate = new Delegate(document.body);
delegate.on('click', 'button', function(event) {
// Do some things
}
);
// Listen to all touch move
// events that reach the body
delegate.on('touchmove', function(event) {
// Do some other things
});
}, false);