您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Replaces direct channel links to go to the videos page.
- // ==UserScript==
- // @name YouTube Channels to Videos
- // @namespace https://www.youtube.com*
- // @version 0.1
- // @description Replaces direct channel links to go to the videos page.
- // @author Ovyerus
- // @match www.youtube.com
- // @grant none
- // @locale en
- // ==/UserScript==
- (function() {
- 'use strict';
- Array.from(document.querySelectorAll('a')).filter(function(a) {
- return /(?:https:\/\/)?(?:www\.)?youtube\.com\/(?:c(?:hannel)?|user)\/[A-z0-9-_]+(?!\/?.+)/i.test(a.href);
- }).forEach(function(a) {a.href += '/videos';});
- })();