Skip to content
This repository has been archived by the owner on Sep 28, 2024. It is now read-only.

Commit

Permalink
Ad-blocker improved and better allow scrolling
Browse files Browse the repository at this point in the history
  • Loading branch information
TheRealJoelmatic authored Oct 19, 2023
1 parent b9d6a6f commit 9a17285
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions Youtube-Ad-blocker-Reminder-Remover.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@
const ad = [...document.querySelectorAll('.ad-showing')][0];
const sidAd = document.querySelector('ytd-action-companion-ad-renderer');
const displayAd = document.querySelector('div#root.style-scope.ytd-display-ad-renderer.yt-simple-endpoint');
const feedAd = document.querySelector('ytd-in-feed-ad-layout-renderer');
if (ad)
{
document.querySelector('video').playbackRate = 10;
Expand All @@ -150,6 +151,9 @@
if (displayAd) {
displayAd.remove();
}
if (feedAd) {
feedAd.remove();
}
}, 50)
}
// Unpause the video Works most of the time
Expand Down Expand Up @@ -184,9 +188,7 @@
}
// Observe and remove ads when new content is loaded dynamically
const observer = new MutationObserver(() =>
{
{
removeJsonPaths(domainsToRemove, jsonPathsToRemove);
});
})();


0 comments on commit 9a17285

Please sign in to comment.