tidy-url
tidy-url copied to clipboard
A node package & userscript that removes tracking or garbage parameters from URLs making them shorter, cleaner and a lot nicer to read.
``` https://www.independent.co.uk/newsletters?itm_audience=prospecting#frameInner https://www.independent.co.uk/login?regSourceMethod=login%20overlay https://www.independent.co.uk/news/uk/crime/how-to-make-sure-you-dont-accidentally-buy-counterfeit-vodka-made-from-anti-freeze-9948447.html?amp ``` - itm_audience - regSourceMethod - amp The `itm` param should be global.
**Website you would like added. Include multiple URLs if needed** ``` https://www.mirror.co.uk/advertising-features/partner-co-op-funeralcare/losing-a-loved-one-suddenly-28326453?int_medium=shop-window-rhc&int_campaign=https%3A%2F%2Fwww.mirror.co.uk%2Fadvertising-features%2Fpartner-co-op-funeralcare%2Flosing-a-loved-one-suddenly-28326453 ``` **Bad parameters. Leave blank if you don't know.** - int_medium - int_campaign
``` https://www.fiverr.com/business?source=side_navigation https://blog.fiverr.com/?source=explore-tab https://www.fiverr.com/categories/graphics-design/creative-logo-design?source=hplo_subcat_first_step&pos=1 ``` **Bad parameters** - source
stats.newswire.com is used to track outbound links. Decode rule is required with `final` as the parameter. ``` https://stats.newswire.com/x/html?final=aHR0cDovL2FuaW1hdGUtb25saW5lc2hvcC5jby5rci9nb29kcy9nb29kc19saXN0LnBocD9jYXRlQ2Q9MDQz&hit%2Csum=WyIzcHcyNzYiLCIzcHcyNzciLCIzcHcyNzEiXQ https://stats.newswire.com/x/html?final=aHR0cHM6Ly9hbmltYXRlYmtrLW9ubGluZS5jb20vZXZhbmdlbGlvbl9waXhpdg&hit%2Csum=WyIzcHcyNzgiLCIzcHcyNzkiLCIzcHcyNzEiXQ https://stats.newswire.com/x/html?final=aHR0cHM6Ly93d3cuZXZhbmdlbGlvbi5jby5qcC8&hit%2Csum=WyIzcHcyN2EiLCIzcHcyN2IiLCIzcHcyNzEiXQ https://stats.newswire.com/x/html?final=aHR0cHM6Ly93d3cucGl4aXYubmV0&hit%2Csum=WyIzcHcyN2MiLCIzcHcyN2QiLCIzcHcyNzEiXQ https://stats.newswire.com/x/html?final=aHR0cHM6Ly93d3cucGl4aXYubmV0L2Fib3V0LnBocD9sYW5nPWVu&hit%2Csum=WyIzcHcyN2UiLCIzcHcyN2YiLCIzcHcyNzEiXQ https://stats.newswire.com/x/html?final=bWFpbHRvOmluZm9AcGl4aXYuY28uanA&hit%2Csum=WyIzcHcyN2ciLCIzcHcyN2giLCIzcHcyNzEiXQ ``` Testing links found [here](https://www.newswire.com/news/pixiv-to-attend-the-anime-and-manga-festival-anime-nyc-with-a-giant-21862811). Example: ```js...
I've had my eye on this domain for a while now because these links are utterly excessive and incredibly annoying. Most decent ad-blockers will block this domain by default, but...
**Links:** ``` https://www.kqzyfj.com/click-2942700-13502820?url=https%3A%2F%2Fwww.dell.com%2Fen-us%2Fshop%2Ftp-link-powerline-av2000-starter-kit-bridge-wall-pluggable%2Fapd%2Fa9266188%2Fnetworking&cjsku=a9266188&pubdata=eyJwbGFjZW1lbnRUeXBlIjoiZHRVZXZVOTYwMzA0In0%3D ``` **Bad parameters:** - pubdata - cjsku **Redirect param:** - url **Additional context** Yet another clickjacking link that's blocked by uBlock origin. Redirect rule required.
**Links:** ``` https://www.lenovo.com/us/en/p/accessories-and-software/wireless-and-networking/wireless-&-networking_range-extenders/78024125?clickid=QOh3r01O5xyNTXZXv1RnE37sUkDXuW2vHUbKxg0&irgwc=1&PID=123412&acid=ww%3Aaffiliate%3Abv0as6&cid=us%3Aaffiliate%3Acxsaam https://support.lenovo.com/partslookup?linkTrack=PartSales_Footer ``` **Bad parameters:** - clickid - irgwc - PID - acid - cid - linkTrack The first 5 params in the list are added by #28's...
**Links:** ``` https://lenovo.vzew.net/c/123412/797408/3808?prodsku=78024125&u=https%3A%2F%2Fwww.lenovo.com%2Fus%2Fen%2Fp%2Faccessories-and-software%2Fwireless-and-networking%2FWireless-%26-Networking_Range-Extenders%2F78024125&intsrc=CATF_5733&subid3=dtUevU960304 ``` **Bad Params:** - prodsku - subid3 - intsrc **Redirect params:** - u This is a simple link tracking domain that's blocked by uBlock origin by default....
### Sample links: ``` https://www.honeycode.aws/?&trk=el_a134p000003yC6YAAU&trkCampaign=pac-edm-2020-honeycode-homepage&sc_channel=el&sc_campaign=pac-edm-2020-honeycode-website_links-adoption-aws_global_menu_products_link&sc_outcome=Enterprise_Digital_Marketing&sc_geo=NAMER&sc_country=mult https://builder.honeycode.aws/auth/signup?trackingId=main-page_get-started-for-free-btn ``` ### Bad parameters: - trackingId ### Additional context The first link contains parameters from #25. It looks like whatever code they have appending...
**Refactor AmpHandler and RedirectHandler into separate modules** - This separation allows for easier maintenance and testing of the individual handlers. - Each handler is responsible for a specific task, making...