cleanurl

package module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 29, 2026 License: MPL-2.0 Imports: 5 Imported by: 0

README

Clean URL

Go Reference

Copy Clean Link for Go, automatically removes tracking parameters like utm_source, si, and utm_campaign from a URL. Uses tracking parameter lists from Firefox and Brave. See ./internal/lists directory.

Usage

link, _ := url.Parse("https://youtu.be/dQw4w9WgXcQ?si=YxOc4tn6Bg0zqKor")
cleanlink := cleanurl.CopyCleanURL(link)
fmt.Println(cleanlink) // https://youtu.be/dQw4w9WgXcQ

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanURL

func CleanURL(u *url.URL)

CleanURL returns u with tracking parameters removed.

func CopyCleanURL

func CopyCleanURL(u *url.URL) *url.URL

CopyCleanURL returns a copy of u with tracking parameters removed.

Types

This section is empty.

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL