After reading this I thought that it would be better if it were an extension that did this without having to click a button and for websites other than twitter. I decided to search and found https://addons.mozilla.org/en-US/firefox/addon/redirector/?utm_source=addons.mozilla.org&utm_medium=referral&utm_content=search
I prefer bookmarklets for a few reasons:
Bookmarklets work on all devices. Deskop, iOS and Android.
I can easily read and understand the code.
They are easy to change. For example in this one, I will probably update the array of nitter instances regularly.
I can organize them just like my other bookmarks.
Sharing a bookmark is as easy as copy/pasting a line of text
For what it’s worth, I really like bookmarklets for the security reasons alone. I know they they aren’t running any code until I click on them (unlike extensions). It’s much easier to check that nothing nefarious is going on behind the scenes. Even the simplest extensions have multiple files of boilerplate code, and they can be updated remotely. I hate to think what would happen if the developer’s account got compromised for any of the popular extensions.
Unfortunately, it seems like Chrome on Android doesn’t support bookmarklets – or at least fails on ones imported from my desktop.
Extensions are updated remotely without user interaction? That is another scary aspect.
For me, the bookmarklet works fine on Chrome on Android. I have to use it from the address bar though. I named it “t2n” and when I am on a Twitter page, I type “t2n” into my address bar. Now from the list of suggestions I click on the bookmarklet and it works.
Bookmarklets can’t get sold to a hostile data-collecting advertising company while you weren’t paying attention.
Yeah these are good points. Have you also see Fraidycat which has slightly different aims?
This looks awesome! I’ve been looking for something similar for a while. Thank you for sharing :)
that’s fair but i personally find extensions more convenient 🤷
Problem with using a redirect extension is:
redirection via an extension sometimes just doesn’t work? not all that surprising I guess.
an extension could pick a random instance just like the bookmarklet though
I’d did not know bookmarklets worked on iOS. That’s pretty rad!
This is the extension I use https://libredirect.github.io/
Privacy Redirect is similar. Found some alternatives I didn’t know about in there.
No need to play the location.href.replace dance, you can simply do
Awesome! I updated the repo.
if the github project is meant to ensure free distribution, I’m pretty sure something this small is not subject to copyright anyway. you could just share the bookmarklet itself instead of a link to a github project:
The GitHub repo has a few benefits.
It will be updated and annotated forever. Since I made this post, I already incorporated multiple improvements people suggested. And it makes collaboration easy. Everyone can add issues and pull requests, make forks or follow the repo.
I’ve been using a userscript on Greasyfork which dynamically replaces all in-page Twitter links with nitter links. I don’t think my browser has opened a connection to Twitter since.
I can see the appeal of solving this with a bookmarklet. It seems easy at first.
Sadly it doesn’t account for changing loads and nitter instances, so it currently only randomizes between three selected instances. And its nearly impossible to deploy a daily updating list via bookmarklets.
Thanks for posting this. They’ve gotten so aggressive lately about trying to force a login that I’d been meaning to find something like this. I think I might just host a Nitter instance on my LAN, and point my bookmarklet at that.