我正在嘗試使用jQuery移動事件,而不使用jQuery移動的其餘部分。擴展jQuery的.on()以使用移動觸摸事件
https://github.com/jvduf/jquery-mobile-events/blob/master/jquery.mobile.events.js
這片段啓用所有這些,和工作正常,但不與。對()事件處理程序。例如:
$('a').on('tap',function(){
console.log('Hi there!');
});
然而,它可以處理.live(),但現在已折舊。
所以我的問題;是否有擴展.on()功能以包含輕擊事件和其他事件的方法?下面名單:
- touchstart
- touchmove
- touchend
- orientationchange
- 自來水
- taphold
- 刷卡
- swipeleft
- swiperight
- scrollstart
- scrollstop
謝謝:)
'on()'的選擇器需要成爲一個父...閱讀on()的幫助非常簡單... – ManseUK 2012-02-16 12:33:42
很酷的提取,但它是如何最新?想想11個月大的時候,這個時候已經很老了,有人維護這個文件嗎? – rball 2012-04-13 16:01:53