Remove Twitch AutoPlay

Removes the annoying auto-playing stream that takes up half the screen in a category

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Forfatter
Ryder7223
Daglige installasjoner
1
Totale installasjoner
15
Vurderinger
0 0 0
Versjon
1.2
Lagd
02.04.2025
Oppdatert
02.04.2025
Size
1 kB
Lisens
CC BY-ND 4.0; You may use this script but not modify or distribute modified versions.
Gjelder

Remove Twitch Short

Overview

This userscript removes the annoying auto-playing stream that takes up a large portion of the screen in Twitch category pages. It works by detecting and removing the intrusive element as soon as it appears.

Features

  • Automatically removes the auto-playing stream in Twitch category pages.
  • Works dynamically with MutationObserver, ensuring the element is deleted even if loaded later.
  • Lightweight and efficient, stops observing after 30 seconds to prevent unnecessary performance impact.

Installation

  1. Install Tampermonkey (or a compatible userscript manager).
  2. Click here to install
  3. Enjoy a cleaner Twitch browsing experience!

Supported URLs

Technical Details

This script uses:

  • querySelectorAll to find and remove the targeted element.
  • MutationObserver to detect and remove dynamically loaded elements.
  • A 30-second timeout to prevent infinite observation.

Source Code

(function() {
  'use strict';

  function removeElements() {
    const els = document.querySelectorAll('div.Layout-sc-1xcs6mc-0.kyIYma');
    els.forEach(el => el.remove());
  }

  // Run once in case the element is already loaded
  removeElements();

  // Create a MutationObserver to watch for dynamically loaded elements
  const observer = new MutationObserver(() => removeElements());

  observer.observe(document.body, { childList: true, subtree: true });

  // Stop observing after a while (optional, to prevent infinite observation)
  setTimeout(() => observer.disconnect(), 30 * 1000); // Stops after 30 seconds
})();