/cache-clear
当前为
// ==UserScript==
// @name Cache Clear Link
// @namespace cache clear
// @version 1.1
// @description /cache-clear
// @match *://*/*
// @grant none
// @license MIT
// @author Samuel Araújo
// @icon https://www.tiptip.pt/public/img/iconTiptip.png
// @description corre rota de cache-clear
// ==/UserScript==
(function () {
if (window.top !== window.self) return; // só executa na janela principal
if (window.top.__clearCacheButtonInjected) return;
window.top.__clearCacheButtonInjected = true;
const link = document.createElement('a');
link.id = 'clear-cache-link';
link.href = `${location.origin}/cache-clear`;
link.textContent = 'clear';
Object.assign(link.style, {
position: 'fixed',
bottom: '20px',
left: '0px',
zIndex: '9999',
padding: '3px 6px',
background: '#f00',
color: '#fff',
textDecoration: 'none',
borderRadius: '4px',
fontSize: '10px',
});
window.top.document.documentElement.appendChild(link);
})();