Skip to content

Instantly share code, notes, and snippets.

@dungsaga
Created July 4, 2022 07:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dungsaga/e6332ba7ad5e9ce6ece3602083edcf88 to your computer and use it in GitHub Desktop.
Save dungsaga/e6332ba7ad5e9ce6ece3602083edcf88 to your computer and use it in GitHub Desktop.
clean up Youtube URLs
// remove "pp=" from query string of all "href" in a Youtube page
for (a of document.getElementsByTagName('a')) { a.setAttribute('href', a.getAttribute('href')?.replace(/&pp=.+/, '')) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment