Skip to content

Instantly share code, notes, and snippets.

@mattscripted
mattscripted / README.md
Last active May 14, 2023 01:58
Remove all videos from "Watched Later" on YouTube

Remove all videos from "Watched Later" on YouTube

For whatever reason, YouTube's "Removed watched videos" button has not worked for years. But since I've maxed out my "Watch Later" list, I can't add anything until I remove videos.

So, this script simply goes through every video in the list and removes it.

With 5,000 videos, it will take about 42 minutes.

@mattscripted
mattscripted / findChristmasSundays.test.ts
Created August 8, 2020 16:23
Test-Driven Development with Christmas Sundays
import findChristmasSundays from './findChristmasSundays'
describe('findChristmasSundays', () => {
it('throws an error, if the start year is not a positive integer', () => {
const expectedError = new Error('startYear must be a positive integer')
expect(() => findChristmasSundays(0.1, 1))
.toThrowError(expectedError)
expect(() => findChristmasSundays(0, 1))
.toThrowError(expectedError)