With just a click, this bookmarklet will redirect you to a foreign community on your native Lemmy instance
It brings your favourite lemmy back home!
If you don’t know what it is, it’s a bookmark that runs a small piece of code that works in all desktop or even mobile browsers
javascript:(function(){
var url = new URL(document.URL);
var baseURL = url.hostname;
var pathname = url.pathname;
window.location.href="https://sopuli.xyz" + pathname + "@" + baseURL;
})();
Usage
- Copy the code, replace “https://sopuli.xyz” in the code to URL of your native instance (for example to “https://lemmy.ca”)
- Create a new bookmark, paste the code from previous step into URL field
- Go to a non native lemmy community
- Click the bookmarklet in your bookmarks bar to activate it.
You must log in or register to comment.
it works. Now Lemmy just needs something like this natively :)
Is this running as userscript in tempermonkey?
No, it’s not. What you have to do is put the block of Javascript on the post into a bookmark on your browser. I suppose one could also make a TamperMonkey-userscript out of this, but this is not that.