Add support for client-side watch history. (#370)

* Add support for client-side watch history.

* Update watched videos more often.
This commit is contained in:
Kavin
2021-08-22 15:57:09 +05:30
committed by GitHub
parent 6688fafeaa
commit 8feb4fbc41
13 changed files with 193 additions and 23 deletions

View File

@@ -44,10 +44,14 @@ export default {
};
},
mounted() {
this.fetchFeed().then(videos => (this.videos = videos));
this.fetchFeed().then(videos => {
this.videos = videos;
this.updateWatched(this.videos);
});
},
activated() {
document.title = "Feed - Piped";
if (this.videos.length > 0) this.updateWatched(this.videos);
},
methods: {
async fetchFeed() {