{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreibf3gkjs3jhomv4nkfrgxbyysby2owgievq25gmvhq6uyxdqkoizi",
"uri": "at://did:plc:hqad6xwuzg7oqfmwylfkvqfm/app.bsky.feed.post/3mmbb7ydekjv2"
},
"path": "/viewtopic.php?t=33148&p=274391#p274391",
"publishedAt": "2026-05-20T05:54:53.000Z",
"site": "http://forum.palemoon.org",
"tags": [
"Simple Sponsor Skipper",
"'GM.addElement(parent, tag, attrs)'"
],
"textContent": "> > > I can't live without Sponsorblock and there's no equivalent for PM.\n>>\n>> In fact, there is one! The Simple Sponsor Skipper, a user script, targets Pale Moon, including on Invidious instances.\n>\n> I tried it today and most I got out of it was the first time configuration prompt. Couldn't access config and it didn't block any such segment. Tried both old and new GreaseMonkey.\n>\n> It worked on Chromium with TamperMonkey without configuring anything specifically.\n\n\nSimple Sponsor Skipper builds its entire configuration UI using 'GM.addElement(parent, tag, attrs)'. The 'GM.addElement' API only exist on Tampermonkey, Violentmonkey, and Scriptcat (Doesn't even exist on the upstream version of Greasemonkey)\n\nMentioning that not even the official Greasemonkey had it, it's safe to assume that it never existed, back when it was forked to Pale Moon, meaning that it definitely does not exist on the old fork of Greasemonkey for Pale Moon.\n\nOn my modern fork of Greasemonkey for UXP: 'GM_addElement' is implemented, but it was going through our generic GM-to-Promise wrapper that all the other 'GM.*' APIs use (since most of them are properly async like 'GM.getValue' / 'GM.xmlHttpRequest'). So instead of returning the element, 'GM.addElement(docHtml, 'head')' was returning Promise'<HTMLHeadElement>'. The script then passed that Promise as the parent of the next call, the wrapper rejected internally (a Promise object has no '.appendChild'), and the rejection got swallowed silently inside the sandbox. TM and VM both return these synchronously; I had this wrong.\n\nI went ahead to see how Violentmonkey applies it in their source code, copied their approach and I tested the userscript with the approach - It is now 100% working (You would have to tick the \"Disable Video ID Hashing (Pale Moon Compatibility Fix)\" box to be enabled, in order for it to work).\n\nSince it's an important userscipt, I want to use it on my daily basis, and nobody reported any instability issues with the beta version of Greasemonkey for UXP 3.7.0, I will release a stable version of it and I will ship this bugfix along with it.\n\nI have no clue why their userscript decided to add an API that only approximately 30+ userscripts utilize it, makes you wonder what does \"simple\" in their userscript name stands for.\n\n* * *",
"title": "General Discussion • Re: Project VORAPIS non-functional",
"updatedAt": "2026-05-20T05:54:53.000Z"
}