listeners;
'mousedown', 'mouseup', 'mousemove'
This should also work for mobiles so for touches:
'touchstart', 'touchend', 'touchmove'
So this means that I should add 6 addEvenetListeners for that element
I want to know is this the right way to go or is there some way to just add 3 which does the same job for touches in mobile and clicks on desktop?
If you haven't found the answer yet, this seems to be a good article to look at: https://web.dev/mobile-touchandmouse/
welcome :)
Обсуждают сегодня