Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Load All Videos #5

Open
ben-miles opened this issue Mar 9, 2024 · 1 comment
Open

Load All Videos #5

ben-miles opened this issue Mar 9, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@ben-miles
Copy link
Owner

Ideally, my code should remove all videos from the playlist which match the search phrase, but for now it can only remove those videos which have been loaded. By default, YouTube shows only the first hundred videos, adding a hundred more every time the user scrolls to the bottom of the page. So, it might be good to investigate some means of loading all the videos in the playlist first. I've done this manually a handful of times and it gets very memory intensive... I experimented a bit with hiding all the video thumbnails (via CSS, using display: none) to see if that would alleviate the issue at all, but that was inconclusive. Perhaps there's a better way via JS, or some other approach entirely.

Barring any kind of real solution, it'd be wise to more clearly indicate to the user that this script is only working on those videos which have been loaded.

@ben-miles ben-miles added the enhancement New feature or request label Mar 9, 2024
@ben-miles ben-miles self-assigned this Mar 9, 2024
@ben-miles
Copy link
Owner Author

Trying out a JS solution (using element.remove() on all thumbnail images) wasn't really any better than the CSS solution. The problem with the browser becoming sluggish or entirely unresponsive when many (1000+) videos are shown likely just comes down to the size of the node list overwhelming the available memory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant