Disable YouTube Video Ads

Disable YouTube video & screen based ads at home page, and right before or in the middle of the main video playback. Also disable YouTube's anti-adblocker popup dialog. For new YouTube layout (Polymer) only.

< Σχολιασμός για τον κώδικα Disable YouTube Video Ads

Αναφορά: Καλός - ο κώδικας λειτουργεί

§
Δημοσιεύτηκε: 30/10/2020
Επεξεργάστηκε: 30/10/2020

Hi @jcunews!

I confirm, your latest v1.2.18 works like a charm for me (I tested it with Firefox Nightly + TamperMonkey).
Your v1.2.18 is the first JS script (I find) that blocks all skippable and non-skippable Youtube' video ads (as I commented you - months ago - in our past contacts, I tested every single JS script, and they can't block non-skippable YT' ads).
I don't know what you did in this last update, but congrats!... it finally works for me. Your v1.2.18 kills all YT' video ads. Thank you!

Please, if possible, just one simple request: I'm not a TamperMonkey' user. Here is the add-on (FireMonkey) I use on my day-to-day browsing: https://addons.mozilla.org/en-US/firefox/addon/firemonkey/
As I said, your v1.2.18 perfectly works with TamperMonkey, but unfortunately it doesn't work with FireMonkey (using v1.2.18 with FF Nightly + FireMonkey, YT' pages appear almost empty).
If by chance you can adapt your v1.2.18 to FireMonkey... it'll be F-A-N-T-A-S-T-I-C!

Thank you in advance!

PS01: I contacted FireMonkey' Dev, below I quote his comment:

Script developer has more intimate knowledge about the script and can debug better.
When running the script it results in Uncaught ReferenceError: ipse is not defined which relates to line 71

if (!ipse && (a = document.querySelector('ytd-watch-flexy')) && (a = a.constructor.prototype) && a.isPlaShelfEnabled_) {

Check with developer to see if that helps.

Another possibility is that since other script manager inject the script manually (not using the dedicated API), the script gets injected a bit later than in FireMonkey.
You can ask the dev to try 'use strict'; which can show some of the common errors.

PS02: Well, the FireMonkey' Dev helped me, he adapted your script, and now it works perfectly in Firefox' Nightly + FireMonkey. For that, line 16 need to be replaced with this bit:

fn = (a, et) => {
let fn, ipse, haia, hca, rp;

Δημοσίευση απάντησης

Συνδεθείτε για να δημοσιεύσετε μια απάντηση.