您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Hide font page posts with fewer than 10 upvotes (edit minimum in the code)
// ==UserScript== // @name Reddit: Low Upvote Filter // @description Hide font page posts with fewer than 10 upvotes (edit minimum in the code) // @match https://www.reddit.com/* // @version 0.1 // @author mica // @namespace greasyfork.org/users/12559 // @license MIT // ==/UserScript== const minUpvote = 10; const observer = new MutationObserver(() => { if (location.pathname == '/') { document.querySelectorAll('button[aria-label="upvote"]:not(.checked)').forEach(element => { if (element.nextSibling.innerText < minUpvote) { element.closest('div.scrollerItem').remove(); } else { element.classList.add('checked'); } }); } }); observer.observe(document.body, { childList: true, subtree: true });