Mercurial > ec-userscripts
annotate youtube-no-shorts.user.js @ 127:a701294f38ff
More reliable state handling
author | nanaya <me@nanaya.net> |
---|---|
date | Sat, 21 Jan 2023 03:15:26 +0900 |
parents | 8de2d53a4cb1 |
children |
rev | line source |
---|---|
93 | 1 // ==UserScript== |
118 | 2 // @name Youtube shorts redirector |
3 // @version 0.1 | |
4 // @description Redirects all youtube shorts videos to normal video pages | |
5 // @author Ultrawipf | |
6 // @match https://*.youtube.com/shorts/* | |
7 // @icon https://upload.wikimedia.org/wikipedia/commons/thumb/f/fc/Youtube_shorts_icon.svg/193px-Youtube_shorts_icon.svg.png | |
8 // @grant none | |
9 // @run-at document-start | |
10 // @downloadURL https://hg.nanaya.net/ec-userscripts/raw-file/tip/youtube-no-shorts.user.js | |
93 | 11 // ==/UserScript== |
12 | |
109 | 13 'use strict'; |
14 | |
93 | 15 // Source: https://gist.github.com/Ultrawipf/7af006d1b8f75eddd3222d1053c3a243 |
117
d9dc190bccaf
Undo combining fixes into single script per site
nanaya <me@nanaya.net>
parents:
109
diff
changeset
|
16 // From https://www.youtube.com/shorts/xxxx to https://www.youtube.com/watch?v=xxxx |
d9dc190bccaf
Undo combining fixes into single script per site
nanaya <me@nanaya.net>
parents:
109
diff
changeset
|
17 window.location = window.location.href.replace('youtube.com/shorts/', 'youtube.com/watch?v='); |