Untitled

 avatar
unknown
plain_text
a year ago
622 B
1
Indexable
// Define the function to click on the body
function clickOnBody() {
    // Create a new mouse click event
    var event = new MouseEvent('click', {
        'view': window,
        'bubbles': true,
        'cancelable': true
    });

    // Dispatch the event to the body element
    document.body.dispatchEvent(event);
}

// Set interval to click every 10 milliseconds
var intervalID = setInterval(clickOnBody, 10);

// To stop the clicking after a certain duration (e.g., 1 minute)
setTimeout(function() {
    clearInterval(intervalID); // Stop the interval
}, 60000); // 60000 milliseconds = 1 minute
Leave a Comment