feat: add optional slug to public note URLs

This commit is contained in:
Julien Calixte
2026-02-17 13:38:45 +01:00
parent c4dd418cd8
commit 5ea5db2655
5 changed files with 27 additions and 4 deletions

View File

@@ -2,6 +2,7 @@
import BackButton from "@/components/BackButton.vue"
import { usePublicNoteList } from "@/hooks/usePublicNoteList.hook"
import { getAuthor } from "@/modules/atproto/getAuthor"
import { slugify } from "@/utils/slugify"
import { computedAsync } from "@vueuse/core"
import { computed } from "vue"
import { vInfiniteScroll } from "@vueuse/components"
@@ -31,7 +32,7 @@ const author = computedAsync(async () => getAuthor(did.value))
<router-link
:to="{
name: 'PublicNoteView',
params: { did: note.did, rkey: note.rkey },
params: { did: note.did, rkey: note.rkey, slug: slugify(note.title) },
}"
class="btn btn-link"
>{{ note.title }}</router-link