Filter twitch chat

Filter chat at twitch.tv script, it removes messages with single word

  1. // ==UserScript==
  2. // @name Filter twitch chat
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.0
  5. // @description Filter chat at twitch.tv script, it removes messages with single word
  6. // @author iiw
  7. // @match https://www.twitch.tv/*
  8. // @grant none
  9. // @require https://code.jquery.com/jquery-2.1.4.min.js
  10. // ==/UserScript==
  11.  
  12. (function() {
  13. 'use strict';
  14.  
  15. // uncomment this if you want hide overlay player controls
  16. // setTimeout(() => $(".hover-display").remove(), 5000);
  17.  
  18. setInterval(function() {
  19. $(".chat-line__message").each(function(_, msg) {
  20. var splitted = msg.innerText.split(" ");
  21. if (splitted.length > 0 && splitted.length < 3) {
  22. $(msg).css("display", "none");
  23. }
  24. });
  25. }, 2);
  26. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址