from tapping the element on the screen to triggering the element's click
event, the mobile browser (touch screen) will have a waiting time of approximately 300 milliseconds. Why is it so designed? Because it wants to see if you're going to double-click (double tap) operation. 300ms of waiting time, will make the user experience greatly impaired, Fastclick.js library is a good solution to this problem.
When using Fastclick, instantiate it on the layer you need to use. We use document.body because we want all the buttons and links to get a quick click.
How to use:
Window.addeventlistener (' Load ', function () { Fastclick.attach (document.body);}, False);
Then using the OnClick event directly, there is no problem with the original 300ms delay.
In addition, there is a way to solve the delay problem, is to use the Zepto.js Library of tap events, but the tap event in the special case there will be a point of penetration, so it is recommended to use the Fastclick.js library.
Troubleshoot latency issues with touch screen device Click event 300ms