Simple Swipe Gesture - Touch Events Handler
A lightweight JavaScript touch events handler that only supports left, right, up and down swipe gestures. Also with 'fast click' for eliminating the 300ms delay.
If you're on a touch device, swipe up, down, left or right to change the colour of the box.
Please view the source of this page for HTML markup and JS.
Scrolling is ON Disable Page Scroll- Swipe UP = Green
- Swipe DOWN = Yellow
- Swipe LEFT = Red
- Swipe RIGHT = Blue
- Tap = Purple
TIP: If up/down swipes are twitchy, toggle the button to disable scroll.
More demos and snippets
Did you find this useful? There are more demos and code snippets this way.