'Uncaught (in promise) Error: Missing required param "tag" - Vue
I use Vue 3. I'm trying to create a dynamic tag list. But i have a problem with the code.
<div class="d-inline-block" >
<router-link v-for="item in profile.tahs.split(',')" v-bind:key="item"
:to="{ name: 'tag', params: { tag: `${item}` } }" >
<span class="badge rounded-pill bg-secondary" style="margin: 1px;">{{ item }}</span></router-link>
</div>
List of tags render normally. But route to each tag is wrong and i get error "vue-router.esm-bundler.js?ec2d:1004 Uncaught (in promise) Error: Missing required param "tag"
i tried do this:
`${item[0]}`
and this show me first letter of tag. So, item isn't empty.
I want to make each tag with route to this tag. How to fix this
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
