corbindavenport / link-cleaner Goto Github PK
View Code? Open in Web Editor NEWProgressive Web App for removing tracking code and other variables from web links
Home Page: https://linkcleaner.app
License: GNU General Public License v3.0
Progressive Web App for removing tracking code and other variables from web links
Home Page: https://linkcleaner.app
License: GNU General Public License v3.0
Links from Macy's lose their function because the link cleaner drops the ID .
https://www.macys.com/shop/product/anthony-veer-mens-roosevelt-ii-double-monk-strap-goodyear-welt-dress-shoe?ID=10920481&CategoryID=70405&sizes=MEN_SHOE_SIZE_T|DRESS_SHOE_TYPE!!11|Monk%20Strap&swatchColor=Red%20Red
becomes:
https://www.macys.com/shop/product/anthony-veer-mens-roosevelt-ii-double-monk-strap-goodyear-welt-dress-shoe
this link doesn't work.
This link works:
https://www.macys.com/shop/product/anthony-veer-mens-roosevelt-ii-double-monk-strap-goodyear-welt-dress-shoe?ID=10920481
As Telegram has skyrocketed in use in the USA, it's my primary share choice on any thing I send.
One of my main reasons I looked for an app like this is because I use the Pixel Launcher search bar which opens the Google app to make a search.
In Android 12 and later, I could open the Recents overview menu and tap the link icon to share directly from the Google app instead of re-searching in Chrome when I wanted to send a search page link.
But the Google app tacked so much stuff it was giant URLs.
Your app kept me from needing that.
However after seeing all your other options to share directly to with, I thought I'd request a Telegram one. (and make the way so it worked universally not the old way that looks only for the specific app, as many use the Telegram PWA, desktop apps, web page, or non-Google Play versions.)
Link Cleaner should override the 'Add to home screen' prompt on Chrome (and other install banners) with a button that explains installing Link Cleaner will add the app to your device's share menu.
Ideally, the override should only happen if both installation and Web Share Target support are present in the browser. Not sure if there's a way to detect Share Target support with JS, since that's defined in the manifest.
https://github.com/FixTweet/FixTweet
Not sure if this should replace vxTwitter, or just be an additional option for Twitter links.
Firstly, thanks for building this, it's exactly what I was hoping I wouldn't have to build myself!
Secondly, what about adding the option to copy & paste a link from Facebook and get back the real URL? I realise that right now that doesn't work.
Here's the URL format:
https://l.facebook.com/l.php?
u=URL_ENCODED_LINK_HERE
&h=TRACKING_PARAM
&__tn__=TRACKING_PARAM
&c[0]=TRACKING_PARAM
I guess a sensible strategy would be:
l.facebook.com
u
parameter from the URLdecodeURIComponent()
on u
fbclid
and other junk) through the current rulesI'd be happy to work on a PR if that's something you're open to. Just let me know.
https://github.com/WICG/manifest-incubations/blob/gh-pages/user-preferences-explainer.md
This is currently an origin trial in Chrome: https://chromestatus.com/feature/5714780426862592
I'll look into implementing once it's fully rolled out.
Links like https://play.google.com/store/apps/details?id=org.videolan.vlc
turn into https://play.google.com/store/apps/details
.
This URL:
https://youtube.com/shorts/lrQRJBgYot0?si=123test
Turns into this URL:
https://youtu.be/null
When I share a tweet in the Twitter PWA, not only the link is shared but also the content:
Corbin Davenport (@corbindavenport) Tweeted:
Check out my podcast @TechTalesShow, where me and a guest talk about wild stories in technology history, from early computers to mobile games.YouTube: https://t.co/zCeEANnIhU
Apple: https://t.co/i5YVCpXGfG
Spotify: https://t.co/WPd90JFmQx
SoundCloud: https://t.co/uf9ii4h7Cc
https://twitter.com/corbindavenport/status/1468665663476617216?s=20&t=Cg4SWcxfa2AqONQ0lz5VLg
Unfortunately, when I then select the Link Cleaner, it does not work.
My idea:
Either URLs should be extracted from the content or the text should be kept and the links replaced with clean links in it.
The best would be a selection in the PWA, where the user can choose one of these options
When sharing links from TikTok, the app generates an unique link that is associated with your account.
For the privacy reasons of me and others I'd like an option to get rid of that.
This could be out of the scope of this project, so please don't be afraid to close the issue :)
After the changes made in commit a268656, the app is not working anymore if the setting page is not open the first time and both checkboxes are flagged (and then unflagged) the first time.
The issue is in rows 24-25 in file js/main.js: without interacting the first time with the checkboxes, getItem
returns a null value and the following toLowerCase()
method will fail.
Lines 24 to 25 in a268656
The same issue should be present in file js/bulk.js on rows 8-9:
Lines 8 to 9 in a268656
Not sure what UI for this would work best, but it could be nice to have a checkbox or something to use TwitFix when cleaning Twitter links.
The app ID gets chopped off.
https://play.google.com/store/apps/details?id=com.microsoft.outlooklite&pcampaignid=web_share
becomes this:
https://play.google.com/store/apps/details
Feature request: "maybe you've gotten this before, but it would be cool to see a history of the recent links you cleaned. like it wouldnt need to remember them all, but maybe just for the current session"
Suggested here: https://twitter.com/LinkofHyrule89/status/1573131451054301185
Not all browsers support writing to the clipboard without a gesture (e.g clicking a button): w3c/clipboard-apis#182
Chromium will also soon require granting a permission before writing to the clipboard without a gesture: https://chromium.googlesource.com/chromium/src/+/10300ac7da93a7e322274f1e
Enabling the setting will probably require asking for a permission first, and only saving the setting if the permission is granted. There can also be a message above the share buttons that says if the result was successfully copied to the clipboard or not. Will need to test in Chrome Canary for future-proofing.
Any chance for adding bulk link cleaning?
Amazon product URLs contain the product's ID, usually after the dp/
. However, some Amazon URLs contain a product/
instead. Looking at shared.js
, it appears that the formula on line 47 only takes into account the URLs with dp/
.
current formula: var regex = /(?:\/dp\/)(\w*|\d*)/g
proposed fix 1 (includes product/
): var regex =/(?:\/dp\/|\/product\/)(\w*|\d*)/g
view formula on regex101.com
proposed fix 2 var regex =/(https?:\/\/(?:www.)?amazon.com\/.*(?:dp|product)\/(\w+))/g
This formula ensured that the URL being processed is indeed from amazon.com, and not another domain.
view formula on regex101.com
Here is an example of an uncleaned URL with product/
.
https://www.amazon.com/gp/product/B01JIYL57K/ref=ppx_yo_dt_b_asin_title_o00_s00?ie=UTF8&psc=1
Regardless, thank for the hard work everyone, linkcleaner.app is an amazing tool.
I just spotted this in the source code:
Lines 4 to 6 in 9719529
This link cleaning tool itself uses Google Analytics, is that correct?
If so, I think I'll likely withdraw my offer to submit a PR in #1. I'm not open to supporting software which advertises a focus on privacy and simultaneously uses Google Analytics. Perhaps there's a compelling reason, or you have a difference of opinion, I'm happy to discuss, but I also want to be upfront with my opinion that the 2 things are not compatible.
I'm starting to see x.com
links in more places, seemingly shared from the Twitter/X app. They're in the same format as Twitter links and redirect to the same page on twitter.com
when resolved:
https://x.com/crinacle/status/1691152430493564928
https://x.com/wojespn/status/1690478468352311297?s=46&t=gEvQlnNLbU9ke0xn1kR1YA
So the FixTweet feature needs to also check for x.com
posts in addition to Twitter posts.
https://github.com/Britmoji/tiktxk
It's similar to the existing twitter link fixer, except for TikTok links.
The button for "Share to Mastodon" doesn't work when Link Cleaner is running from the Edge sidebar, presumably because Edge doesn't allow browser-level alerts. Need to check for other similar alerts in the app.
Any link from Google search results that is put through linkcleaner results in output of just "https://www.google.com/url"
Tried this link:
https://facebook.com /story.php?story_fbid= 592076618953822&id= 100044544666004
I just got
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.