From 9840725e306ebe805aad2659ab8d27d63cada97b Mon Sep 17 00:00:00 2001 From: Faris Ansari Date: Wed, 8 Jan 2025 16:22:28 +0530 Subject: [PATCH] feat: remember last feed tab in home --- frontend/src/pages/Discussions.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/frontend/src/pages/Discussions.vue b/frontend/src/pages/Discussions.vue index 6e437d83..ceb90791 100644 --- a/frontend/src/pages/Discussions.vue +++ b/frontend/src/pages/Discussions.vue @@ -39,8 +39,12 @@ import { computed, ref } from 'vue' import { Breadcrumbs, Select, TabButtons, usePageMeta } from 'frappe-ui' import DiscussionList from '@/components/DiscussionList.vue' import LastPostReminder from '@/components/LastPostReminder.vue' +import { useLocalStorage } from '@vueuse/core' -const feedType = ref('following') +const feedType = useLocalStorage<'following' | 'participating' | 'recent'>( + 'homeFeedType', + 'following', +) const orderBy = ref('last_post_at desc') const filters = computed(() => {