您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
2/6/2020, 10:34:31 PM
// ==UserScript== // @name remove_trending - twitter.com // @namespace Violentmonkey Scripts // @match https://twitter.com/* // @grant none // @version 1.0 // @author fudgepop01 // @description 2/6/2020, 10:34:31 PM // ==/UserScript== const deleter = () => { const possibilities = document.querySelectorAll("section > h1"); let found = false; for (const possible of possibilities) { if (possible.innerText.toLowerCase() === 'trending now') { possible.parentNode.parentNode.parentNode.parentNode.remove(); found = true; break; } } if (!found) requestAnimationFrame(deleter); } setInterval( () => { if (window.location.href !== window.oldHref) deleter(); window.oldHref = window.location.href; }, 50)