A clean and minimal youtube frontend, without all the ads and whistles
JavaScript
order videos for downloaded and summarized
Christian Feicd4541c3991e
diff --git a/client/main.js b/client/main.jsindex 67dbbc3..cda3847 100644--- a/client/main.js+++ b/client/main.js@@ -25,12 +25,13 @@ eventSource.onmessage = (message) => {if (data.type === 'all' && data.videos) {$videosContainer.innerHTML = ''- const allVideos = Object.entries(data.videos).reduce((acc, curr) => acc.concat(curr[1]), [])- allVideos+ let allVideos = Object.entries(data.videos).reduce((acc, curr) => acc.concat(curr[1]), [])+ allVideos = allVideos.filter(video => !window.store.includes(window.store.ignoreVideoKey, video.id)).sort((a, b) => +new Date(b.publishedAt) - +new Date(a.publishedAt))- .forEach(video => {+ .map(video => {$videosContainer.appendChild(createVideoElement(video))+ return video})updateDownloadedVideos(allVideos)