view youtube-no-shorts.user.js @ 103:b2d0b37f945f

Update mandarake script - update download url - remove iife - run at document start - use observer - remove search link fixer (seems to be fixed already)
author nanaya <me@nanaya.net>
date Sat, 24 Dec 2022 22:10:30 +0900
parents 5510cbaabcac
children 2c4470b73ad9
line wrap: on
line source

// ==UserScript==
// @name         Youtube shorts redirector
// @version      0.1
// @description  Redirects all youtube shorts videos to normal video pages
// @author       Ultrawipf
// @match        https://*.youtube.com/shorts/*
// @icon         https://upload.wikimedia.org/wikipedia/commons/thumb/f/fc/Youtube_shorts_icon.svg/193px-Youtube_shorts_icon.svg.png
// @grant        none
// @run-at       document-start
// ==/UserScript==

// Source: https://gist.github.com/Ultrawipf/7af006d1b8f75eddd3222d1053c3a243
(function () {
  'use strict'
  // From https://www.youtube.com/shorts/xxxx to https://www.youtube.com/watch?v=xxxx

  window.location = window.location.href.replace('youtube.com/shorts/', 'youtube.com/watch?v=')
})()