Created
December 8, 2023 16:04
-
-
Save rmnmjw/b670bff8f0d544ff8ee25ce3bd5f7a60 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name MailHog QuickDelete | |
// @namespace Violentmonkey Scripts | |
// @match http://localhost:8025/ | |
// @grant none | |
// @version 1.0 | |
// @author - | |
// @description 5.4.2023, 19:05:12 | |
// ==/UserScript== | |
const observer = new MutationObserver((/*mutations*/) => { | |
const el = document.querySelector('[ng-click="deleteAllConfirm()"]'); | |
if (!el) { | |
return; | |
} | |
el.click() | |
}); | |
observer.observe(document.body, { | |
childList: true | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment