Edit: Replies to this thread indicate this is not fully correct as it exists on all browsers; and is likely an ad thing.

  • Superb@lemmy.blahaj.zone
    link
    fedilink
    English
    arrow-up
    176
    arrow-down
    4
    ·
    7 months ago

    If the person who tweeted this scrolled down in the hackernews thread, they’d see this code was misinterpreted. It’s part of an anti Adblock script that runs 5s after page load. Still shitty, but less insidious

  • HeChomk@lemmy.world
    link
    fedilink
    English
    arrow-up
    79
    arrow-down
    6
    ·
    7 months ago

    Don’t use the youtube website. On any browser. Use freetube instead, if your situation and use case allows it. No Google bullshit required. Loads fast, no ads, no tracking. Fully self contained.

    • Virkkunen@kbin.social
      link
      fedilink
      arrow-up
      55
      arrow-down
      3
      ·
      7 months ago

      I really appreciate you saying “if your situation and use case allows it”. I’m sick of people “suggesting” these kind of things by just saying “don’t do this” “stop doing that” while completely ignoring that not everyone has the same use cases, preferences and possibilities for such.

    • Fisch@lemmy.ml
      link
      fedilink
      arrow-up
      5
      ·
      7 months ago

      I wish there was a GTK Piped client. Freetube has that kinda janky feeling of a browser (it’s an Electron app, so not surprising) and I don’t see why I wouldn’t just use Piped in a browser then.

    • CluckN@lemmy.world
      link
      fedilink
      arrow-up
      4
      ·
      7 months ago

      Does freetube show recommendations? Most free clients seem to scrape your subscriptions and lack features like playlists.

  • Echo Dot@feddit.uk
    link
    fedilink
    arrow-up
    64
    arrow-down
    7
    ·
    7 months ago

    Whoever posted this is not a programmer. Does no conditional on that code so it would run on every browser on every session so where’s the check for Firefox?

    Unless they are claiming that it is injected at runtime. But that’s easily provable/disprovable with agent spoofing.

    • heavyboots@lemmy.ml
      link
      fedilink
      English
      arrow-up
      34
      arrow-down
      1
      ·
      edit-2
      7 months ago

      In the demo I saw they did an agent spoofing to Chrome and the delay went away, but it didn’t look very extensively tested. As others said, the disappearance on reload could easily be because they thought he was returning to the page and had already seen the ad/been punished for not seeing the ad and so something ad-related disappeared instead.

      • idunnololz@lemmy.world
        link
        fedilink
        arrow-up
        18
        ·
        7 months ago

        Iirc the thing is it loads a different js file when it detects chrome which doesn’t have the 5s delay. The reasoning is this is part of some anti adblocker code and chrome didn’t need the extra logic.

        • Echo Dot@feddit.uk
          link
          fedilink
          arrow-up
          5
          arrow-down
          5
          ·
          7 months ago

          So it’s got nothing to do with Firefox it’s to do with preventing and blocking so it’ll happen on Chrome as well.

            • Echo Dot@feddit.uk
              link
              fedilink
              arrow-up
              4
              arrow-down
              1
              ·
              7 months ago

              Chrome doesn’t need a 5 second delay to implement ad blocking, or Chrome doesn’t need a five second delay because it’s Chrome?

              Does an important difference here because one is anti-competitive and the other isn’t.

  • FuckyWucky [none/use name]@hexbear.net
    link
    fedilink
    English
    arrow-up
    12
    arrow-down
    1
    ·
    7 months ago

    yea there does appear to be delay but it doesnt target firefox users specifically (i think) or atleast isn’t obvious to me cuz the code is obfuscated. more likely related to ads (since there is a 5 second delay before you can skip ads). anti-adblock maybe yes.

  • SootySootySoot [any]@hexbear.net
    link
    fedilink
    English
    arrow-up
    6
    ·
    edit-2
    7 months ago

    uBlock on firefox here, no User Agent spoofing, videos load in ~1-2 seconds as normal still. Wouldn’t surprise me if it’s used in nicher circumstances though.