Skip to content

Instantly share code, notes, and snippets.

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 Hans5958/b074a69b9756619d69c2bb58b25506bb to your computer and use it in GitHub Desktop.
Save Hans5958/b074a69b9756619d69c2bb58b25506bb to your computer and use it in GitHub Desktop.
Remove all videos from a YouTube playlist. Open a playlist page and run this script. Adjust the interval time if needed, but as low as 50, or maybe lower, should be fine.
setInterval(() => {
document.querySelector('.ytd-playlist-video-list-renderer #menu yt-icon.style-scope.ytd-menu-renderer').click()
setTimeout(() => document.querySelector('#items > ytd-menu-service-item-renderer:nth-child(4) > tp-yt-paper-item > yt-formatted-string').click(), 1)
}, 100)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment