explorer-app/pages/category/[id].vue
2023-12-19 18:43:42 +01:00

15 lines
334 B
Vue

<script lang="ts" setup>
const dataStore = useData()
const { selectedCategoryId, filteredProjects } = storeToRefs(dataStore)
const route = useRoute()
onMounted(() => {
if (route.params.id)
selectedCategoryId.value = route.params.id as string
})
</script>
<template>
<ProjectGrid :projects="filteredProjects" />
</template>