💾 Archived View for woodpeckersnest.space › ~schapps › projects › cleanurls.gmi captured on 2024-12-17 at 09:46:54. Gemini links have been rewritten to link to archived content

View Raw

More Information

-=-=-=-=-=-=-

Clean URLs

Original URL Redirector and Fixer

Remove needless parameters from a given URL and correct it to a cleaner one.

About

This script was started as a proof of concept of utilizing the URL API instead of RegEx.

To add a new hash or parameter, simply add it to the respective array.

Enjoy graceful sharing!

Legend and visual examples

l) Discovered URL
   URL found within a parameter

w) Pure link
   URL without parameters (mere pathname)

g) Safe link
   URL with whitelisted parameters

y) Semi-safe link
   URL purged by blacklist

r) Unsafe link
   Original URL (useful in rare cases)

        orderBy orderDir src ref version source url Custom   Visual Example
Link №1 ✓       ✓        ✓   ✓   ✕       ✕      ✕   ✕         (l)(w)(g)(r)
Link №2 ✓       ✓        ✕   ✕   ✓       ✕      ✕   ✕         None
Link №3 ✓       ✓        ✕   ✓   ✓       ✕      ✕   ✕         (w)(g)(r)
Link №4 ✓       ✓        ✕   ✓   ✓       ✓      ✓   /ref=     (l)(l)(w)(g)(y)(r)
Link №5 ✓       ✓        ✓   ✕   ✓       ✕      ✕   465933    (l)(w)(g)(y)(r)
Link №6 ✓       ✓        ✕   ✕   ✓       ✕      ✓   ✕         (l)(w)(g)(y)
Link №7 ✕       ✕        ✕   ✓   ✕       ✕      ✕   slackware (l)(w)(r)
Link №8 ✕       ✕        ✕   ✕   ✕       ✓      ✕             (l)(w)(y)

Resources

Greasy Fork

OpenUserJS