您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Redirects gyazo.com -> i.gyazo.com
// ==UserScript== // @name Gyazo Redirector // @author brian6932 // @namespace https://gf.qytechs.cn/users/581142 // @namespace https://github.com/brian6932 // @license agpl-3.0-only // @description Redirects gyazo.com -> i.gyazo.com // @include /^ht{2}ps:\/{2}gyazo\.com\/[\da-f]+$/ // @grant GM_xmlhttpRequest // @run-at document-start // @version 1.5 // ==/UserScript== // jshint esversion: 11 'use-strict' const redirect = () => GM_xmlhttpRequest({ url: 'https://api.gyazo.com/api/oembed?url=' + globalThis.location.href, responseType: 'json', onload: _ => globalThis.location.href = _.response.url ?? (() => { throw globalThis.Error('OEmbed request failed') })() }), eventType = 'beforescriptexecute' // Chromium and WebKit don't support this for some reason, and I cba to use a polyfill here. if (GM_info.platform.browserName === 'Firefox' || globalThis.geteventTypeListeners?.(globalThis).hasOwnProperty(eventType)) globalThis.addEventListener(eventType, redirect) else redirect()
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址