Useful JavaScript snippet when you are watching that online Videos

Hi guys, I was searching for something on StackOverflow and found this topic. I’m not suggesting you to do it, just educational information, that this JavaScript code is somehow useful. I don’t know how it works technically but it works. It works like an invisible hand to click that button to do that thing…

javascript:(function(){setInterval(function() { var $cross = document.getElementsByClassName("ytp-ad-overlay-close-container")[0]; var $skip = document.getElementsByClassName("ytp-ad-skip-button")[0]; if ($cross != undefined) $; if ($skip != undefined) $ }, 2000)})();

Leave a Reply

Your email address will not be published. Required fields are marked *