refacto to use ref route query

This commit is contained in:
Julien Calixte
2023-08-15 01:08:08 +02:00
parent 11831e1ca6
commit 43b99eed52
9 changed files with 94 additions and 125 deletions

View File

@@ -1,20 +1,14 @@
<script lang="ts" setup>
import { computed, defineAsyncComponent, onMounted } from 'vue'
import { computed, defineAsyncComponent } from 'vue'
import { useFile } from '@/hooks/useFile.hook'
import { useQueryStackedNotes } from '@/hooks/useQueryStackedNotes.hook'
const FluxNote = defineAsyncComponent(() => import('@/components/FluxNote.vue'))
const props = defineProps<{ user: string; repo: string; note: string }>()
const { resetStackedNotes } = useQueryStackedNotes()
const note = computed(() => props.note)
const { content } = useFile(note)
onMounted(() => {
resetStackedNotes()
})
</script>
<template>