您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Disables elements that lead to YouTube Shorts.
当前为
// ==UserScript== // @name 🚫 ShortsOff! - YouTube Shorts Remover // @icon https://solabs.neocities.org/assets/no_shorts!.png // @license GNU GPL v3.0; http://www.gnu.org/licenses/gpl-3.0.txt // @match https://www.youtube.com/* // @version 1.1 // @author Boon! // @description Disables elements that lead to YouTube Shorts. // @namespace https://gf.qytechs.cn/users/1398226 // ==/UserScript== console.log("[ShortsOff!] Boop!") // Remove shorts category when searching. function removeShortsSearchCategory() { const elements = document.querySelectorAll('yt-formatted-string[title="Shorts"]'); elements.forEach(element => { if (element) { element.parentElement.remove(); } }); } // Removes the shorts endpoint link at the sidebar. function removeShortsEndpointLinks() { const elements = document.querySelectorAll('a[title="Shorts"]'); elements.forEach(element => { if (element) { element.remove(); } }); } // Removes the recommended shorts at the homepage. function removeIsShorts() { const elements = document.querySelectorAll('[is-shorts]'); elements.forEach(element => { if (element) { element.remove(); } }); } // Removes the recommended shorts at the side while watching a video. function removeYtdReels() { const elements = document.querySelectorAll('ytd-reel-shelf-renderer'); elements.forEach(element => { if (element) { element.remove(); } }); } // Main function function main() { removeShortsEndpointLinks(); removeIsShorts(); removeYtdReels(); removeShortsSearchCategory() } // Initialize an observer that runs the main function when an element is modified. const observer = new MutationObserver(main); observer.observe(document.body, { childList: true, subtree: true });
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址