touchmove Event in JavaScript
touchmove Event in JavaScript
The touchmove event is used to trigger when user moves the finger across the screen. It will be triggered once for each movement and will continue to be triggered until the finger is released. It will only work with devices that have a touch screen.
Its relative events are:-
- touchstart i.e, it occurs when the user touches an element
- touchcancel i.e, it occurs when the touch is interrupted
- touchend i.e, it occurs when the user removes the finger from an element
Syntax:-
Its syntax is:- < element ontouchmove="my_script" > OR object.ontouchmove= function(){my_script} OR object.addEventListener("touchmove", my_script)