Greasy Fork is available in English.
Search GleasyFork or Sleasyforks for scripts of the current site
// ==UserScript==
// @name Search Scripts on GreasyFork/Sleazyfork
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Search GleasyFork or Sleasyforks for scripts of the current site
// @author You
// @match *://*/*
// @license MIT
// @grant GM_openInTab
// @grant GM_registerMenuCommand
// ==/UserScript==
(function() {
'use strict';
let domain = window.location.hostname;
// www.を削除
if (domain.startsWith('www.')) {
domain = domain.substring(4);
}
// GreasyForkで検索
if (typeof GM_registerMenuCommand !== 'undefined') {
GM_registerMenuCommand(`Search GreasyFork for ${domain}`, function() {
const url = `https://greasyfork.org/ja/scripts/by-site/${domain}?filter_locale=0`;
GM_openInTab(url, false);
});
// Sleazyforkで検索
GM_registerMenuCommand(`Search Sleazyfork for ${domain}`, function() {
const url = `https://sleazyfork.org/ja/scripts/by-site/${domain}?filter_locale=0`;
GM_openInTab(url, false);
});
}
})();