Hacker News new | ask | show | jobs
by uwu 3091 days ago
> I wish chrome added an option for tampermonkey scripts to be run with disabled js, that would make this solution perfect.

that's up to tampermonkey but maybe it's possible that google wouldn't like it since it would let userscripts access extension apis

what tampermonkey does is inserting the script into the page in a script tag to isolate it from the extension[1] and let it access variables defined by scripts on the page, but if scripts are blocked on the page it just doesn't run

i made my own custom js manager (with no userscript api support) that lets you choose if the script should be ran in the extension or page context (defaults to extension which works with scripts blocked) but i don't know if it's in good enough state to put on the internet and i've never really made things for anyone but myself

[1] https://developer.chrome.com/extensions/content_scripts#exec...

1 comments

I know, author of tampermonkey is waiting for this https://bugs.chromium.org/p/chromium/issues/detail?id=471801 to be implemented. As for the extension that's up to you :) you can just post it on github and not to the store.