mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-11 20:40:20 +00:00
added tests
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
/// <reference path="domready.d.ts" />
|
||||
|
||||
domready(function () {
|
||||
// dom is loaded!
|
||||
})
|
||||
@@ -0,0 +1,19 @@
|
||||
/// <reference path="ftdomdelegate.d.ts" />
|
||||
|
||||
function handleButtonClicks(event) {
|
||||
// Do some things
|
||||
}
|
||||
|
||||
function handleTouchMove(event) {
|
||||
// Do some other things
|
||||
}
|
||||
|
||||
window.addEventListener('load', function() {
|
||||
var delegate = new Delegate(document.body);
|
||||
delegate.on('click', 'button', handleButtonClicks);
|
||||
|
||||
// Listen to all touch move
|
||||
// events that reach the body
|
||||
delegate.on('touchmove', handleTouchMove);
|
||||
|
||||
}, false);
|
||||
Reference in New Issue
Block a user