Clickable tags by nuxt-link

This commit is contained in:
Tomas Bednarik 2019-11-03 12:34:56 +01:00
parent 194178627d
commit c3d28af321

View File

@ -1,6 +1,6 @@
<template>
<ds-tag>
<a v-bind:href="`/?hashtag=${id}`" target="_blank">#{{ id }}</a>
<nuxt-link :to="hashtagUrl">#{{ id }}</nuxt-link>
</ds-tag>
</template>
@ -10,5 +10,10 @@ export default {
props: {
id: { type: String, required: true },
},
computed: {
hashtagUrl() {
return `/?hashtag=${this.id}`
},
},
}
</script>