A clean and minimal youtube frontend, without all the ads and whistles
JavaScript
chore: max 10 vids per channel, max 500 vids
Christian Fei1ad19e1684b3
diff --git a/lib/repository.js b/lib/repository.jsindex 215a5b9..0a53d0b 100644--- a/lib/repository.js+++ b/lib/repository.js@@ -34,7 +34,7 @@ export default class Repository {getVideos () {return this.videos.sort((a, b) => +new Date(b.publishedAt) - +new Date(a.publishedAt))- // .filter((_, i) => i < 2000)+ .filter((_, i) => i < 500)}getVideo(id) {return this.videos.find(v => v.id === id)diff --git a/lib/youtube.js b/lib/youtube.jsindex 2e1b0af..fa4e412 100644--- a/lib/youtube.js+++ b/lib/youtube.js@@ -86,7 +86,7 @@ export async function getVideosFor(channelName) {.map(toInternalVideo).filter(Boolean)// .filter(v => v.publishedAt > new Date(Date.now() - 31 * 24 * 60 * 60 * 1000))- .filter((_,i) => i < 30)+ .filter((_,i) => i < 10)} catch (error) {console.error('Error fetching latest video:', error.message)return null