Skip to content

Commit

Permalink
🐛 fix(appfilter.vue): add realtime list update
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinsOnuoha committed Oct 27, 2023
1 parent cac028e commit 099ab8c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/AppFilter/AppFilter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,14 @@ const selectCategory = (category: Category) => {
closeDropdown()
}
const filterCategories = () => {
categoriesList.value = categories
if (filterValue.value) {
categoriesList.value = categoriesList.value.filter((category) =>
category.name.toLowerCase().includes(filterValue.value.toLowerCase())
)
return
}
categoriesList.value = categories
}
</script>

Expand Down

0 comments on commit 099ab8c

Please sign in to comment.