Open in RemovePayWall

Open the current page with RemovePayWall from the Tampermonkey menu button, single-tab guaranteed

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(У мене вже є менеджер скриптів, дайте мені встановити його!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Open in RemovePayWall
// @namespace    http://tampermonkey.net/
// @version      1.4
// @description  Open the current page with RemovePayWall from the Tampermonkey menu button, single-tab guaranteed
// @author       rogierg
// @license      MIT
// @match        *://*/*
// @grant        GM_registerMenuCommand
// @grant        GM_openInTab
// @run-at       document-idle
// @icon         https://www.removepaywall.com/faviFold/favicon-16x16.png
// ==/UserScript==

(function() {
    'use strict';

    // Only register once per top-level page
    if (!window.top._removePaywallMenuRegistered) {
        window.top._removePaywallMenuRegistered = true;

        GM_registerMenuCommand("Open current page in RemovePayWall", function() {
            const url = encodeURIComponent(location.href);
            GM_openInTab("https://www.removepaywall.com/search?url=" + url, { active: true });
        });
    }
})();