YouTube JS Engine Tamer

To enhance YouTube performance by modifying YouTube JS Engine

< Σχολιασμός για τον κώδικα YouTube JS Engine Tamer

Ερώτηση/σχόλιο

§
Δημοσιεύτηκε: 20/05/2025

Firefox
Violentmonkey
script v0.37.6

I can't open the collapsed live chat

§
Δημοσιεύτηκε: 20/05/2025

15:14:22.763 TypeError: this.document is null ChatIframe.js:31:5

Showing this everytime I click it

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025

There is no "ChatIframe.js" in YouTube.

I think it could be due to conflicts with your other browser extensions or userscripts.

Please disable them all first and try again. Then test one by one to see which caused the conflict.

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025

Are you using an extension called "YouTube Livestreams Theater Mode" ?

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025

I can reproduce your issue using YouTube Livestreams Theater Mode

I have tried a bit, and I don't think it is working well in the current latest YouTube stable layout.

Anyway, I think there are some conflicts with it. You might have to disable either one of them to use YouTube.

§
Δημοσιεύτηκε: 20/05/2025

Now it works, I don't know why but now I can't close the chat and it will always load

§
Δημοσιεύτηκε: 20/05/2025

"Now it works" I mean without disabling anything, I just restart the browser

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025
Επεξεργάστηκε: 20/05/2025

There is a bug in its coding.

  initDocument() {
    this.document = this.element.contentDocument;
    this.html = this.document.querySelector('html');
    if(this.isReady()) {
      this.initContent();
    }
    else {
      setTimeout(this.initDocument.bind(this), 100);
    }
  }

Change

this.html = this.document.querySelector('html');

to

this.html = this.document?.querySelector('html');

I cannot find a proper way to report the issue to the author.

You might ask him to join the discussion here or GitHub.

https://napalighost.com/youtube-livestreams-theater-mode

§
Δημοσιεύτηκε: 20/05/2025

The same after disabling "YouTube Livestreams Theater Mode"

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025

The same after disabling "YouTube Livestreams Theater Mode"

What is the error message now?

15:14:22.763 TypeError: this.document is null ChatIframe.js:31:5 would not appear if you have disabled "YouTube Livestreams Theater Mode"

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025
Επεξεργάστηκε: 20/05/2025

Oh. You are right. Let me find out the root cause and get back to you.

It seems to be Firefox specific.

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 20/05/2025

I have found the cause which is the bug in this script.

Fixed in 0.37.7.

You can use "YouTube Livestreams Theater Mode" as well. (it seems no conflict)

§
Δημοσιεύτηκε: 20/05/2025

The fix works, I use a script that made the chat auto collapse and it stops working. Thank you.

§
Δημοσιεύτηκε: 06/06/2025

The live chat will get stuck after a while

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 08/06/2025

The live chat will get stuck after a while

Yes... I feel the same... I am not sure whether it is caused by this script, or YouTube Super Fast Chat, or conflict between both.

I cannot locate the root cause at this moment...

𝖢𝖸 𝖥𝗎𝗇𝗀Δημιουργός
§
Δημοσιεύτηκε: 08/06/2025

The live chat will get stuck after a while

I just lighted upon that, I should have found the issue that making the chat message get sucked, and fixed some days ago.

Make sure you have updated "YouTube Super Fast Chat" to v0.102.9 (or later) and try again.

Tell me if it does not work for you.

§
Δημοσιεύτηκε: 08/06/2025

it got fix somehow

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

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

长期地址
遇到问题?请前往 GitHub 提 Issues。