alexgibson / tap.js

DEPRECATED - A custom 'tap' event JavaScript plugin for touch devices
Other
349 stars 65 forks source link

Fastclick Alternative #10

Closed jakiestfu closed 11 years ago

jakiestfu commented 11 years ago

I have always used Fastclick for my projects, but yours appears to be the optimal solution by far.

Why do you think Fastclick is so much larget than Tap.js?

alexgibson commented 11 years ago

Fastclick is built to capture all links / click events on the page, so there are many more edge-cases it must workaround I guess. Tap.js is built more for use on certain elements which the developer selectively chooses, so is more lightweight. It was just built for my own use originally, but others have found it useful.

Am going to close this as it's not really an issue - but feel free to email me if you would like to discuss further.

jakiestfu commented 11 years ago

Does your library not delegate events? i.e. couldn't I apply tap.js to the body and have it trickle down to all elements?

alexgibson commented 11 years ago

Yes, sure see here for an example:

https://github.com/alexgibson/checklist/blob/master/js/main.js#L477