This is how I simulate a click in a web browser:
$(document).ready(function() {
$("button").click();
});
But how can I simulate a vclick instead? The reason is I want to automate a tap on mobile devices. Any ideas?
This is how I simulate a click in a web browser:
$(document).ready(function() {
$("button").click();
});
But how can I simulate a vclick instead? The reason is I want to automate a tap on mobile devices. Any ideas?
I suppose you can use this:
$('button').trigger('vclick');
Use vclick with caution! See https://api.jquerymobile.com/vclick/
Update: possible alternative
$('button').trigger('tap');
See also: Eliminate 300ms delay on click events in mobile Safari
Update: did you try/know Hammer.js? Take a look at http://hammerjs.github.io/recognizer-tap/ and http://hammerjs.github.io/tips/