64
submitted 1 year ago by Azzu@lemm.ee to c/fediverse@lemmy.world

Description

Lemmy Universal Link Switcher, or LULs for short, scans all links on all websites, and if any link points to a Lemmy instance that is not your main/home instance, it rewrites the link so that it instead points to your main instance.

Also works on Firefox Android with the Tampermonkey extension!

Features

  • Rewrite links to Lemmy posts/comments to point to your home instance. Only after hovering over them, because getting home posts/comments links require communicating with the Lemmy servers, and we don't want to spam the servers.
    video demonstrating links to posts being rewritten

  • Instantly rewrite all links of community or user links to Lemmy/kbin on all websites everywhere to your new instance! The rewritten links will have an icon next to it, and hovering/touching the icon will show you the original link, allowing you to go there if you want to.
    community links being rewritten

  • If you are already on a page that has a corresponding page on your home instance, a link will automatically be added to the page header.
    the header link to your home instance when already on a remote post

Home Instance Setup

Simply visit the Lemmy instance you want to set as your home while the script is active. You will be asked if you want to set this instance to your home instance:
popup to select home instance

If you initially set your home instance wrong or just want to change it, no worries - simply go to your settings on your new home instance and press the button for it!
button to set your new home instance

Common Issues

Coming soon

  • Rewrite kbin post/comment links
  • Better rewriting support for kbin community/user urls (e.g. sort options are currently ignored)
  • Nicer tooltip styling (fit into page theme)
  • Signify that "Show at home" button is loading for posts/comments
top 12 comments
sorted by: hot top controversial new old
[-] Seltzer@lemmy.world 3 points 1 year ago

Kickass dude. Thanks!

[-] desertcreosote@purpleit.net 1 points 1 year ago

Are there any plans to allow users to define a custom Lemmy/Kbin instance without needing to edit the script to add the instance URL? (is that what you meant by "better rewriting support for kbin community/user urls"?)

[-] Azzu@lemm.ee 3 points 1 year ago

Yeah I will add this, I actually also want to make the updating of which instances are in the script automatic, or at least everyone be able to trigger an update from the settings page. Update it from some instance list API, which should hopefully also pick up more recent instances as soon as they start federating.

[-] desertcreosote@purpleit.net 1 points 1 year ago

That's fantastic, thank you!

[-] Azzu@lemm.ee 2 points 1 year ago

Unfortunately your purpleit.net instance didn't turn up on https://lemmyverse.net/, so when I just updated my instance list it didn't get added, so you'll probably have to re-edit your script file, sorry :( but that custom definition feature is coming soon!

[-] amanaftermidnight@lemmy.world 1 points 1 year ago

I kinda wish it supports more than one home instances as I'm currently rocking 2 of them.

[-] Azzu@lemm.ee 1 points 1 year ago

Yeah this will be my next feature because I also have an account on lemmynsfw.com :D

[-] Azzu@lemm.ee 1 points 1 year ago

Just wondering how you thought best to handle it? I'd think:

  1. case: on one of the home instances -> all links (even to the other home instance) get rewritten to the current instance you're on
  2. case: external instance/webpage -> all links get rewritten to the new "main" home instance
[-] Coelacanth@lemmy.world 1 points 1 year ago

This works great, but I can't get it working with Kbin. Since the settings menu looks different there I can't find the button to switch home instance. Where should I look? Otherwise this works well.

[-] Azzu@lemm.ee 1 points 1 year ago

Sorry, I didn't really build this with kbin users in mind, since I also don't use kbin. My motivation to add features I wouldn't get a benefit from is quite low, I'm so selfish to say :D but maybe I'll get around to it.

[-] Coelacanth@lemmy.world 1 points 1 year ago

I'm mostly using Lemmy too since Kbin has some issues, but many people seem to enjoy it so I keep an account there too just in case. Honestly I'd maybe use it more if your script worked on it haha. Anyway, I'll keep tracking this just in case, and as I said it's been great so far for Lemmy.

[-] xapr@lemmy.sdf.org 1 points 1 year ago

Cool idea, thanks for making this!

this post was submitted on 03 Jul 2023
64 points (100.0% liked)

Fediverse

28262 readers
654 users here now

A community to talk about the Fediverse and all it's related services using ActivityPub (Mastodon, Lemmy, KBin, etc).

If you wanted to get help with moderating your own community then head over to !moderators@lemmy.world!

Rules

Learn more at these websites: Join The Fediverse Wiki, Fediverse.info, Wikipedia Page, The Federation Info (Stats), FediDB (Stats), Sub Rehab (Reddit Migration), Search Lemmy

founded 1 year ago
MODERATORS