Answers for "change route name dynamic vue"

2

vue router link dynamic id

<div class="category-list" v-for="category in categories">
    <router-link :to="{ name: 'category/edit', params: { categoryId: category.id }}">Home</router-link>
</div>
Posted by: Guest on September-15-2020
3

get params from route vuejs

const User = {
  template: '<div>User {{ $route.params.id }}</div>'
}
Posted by: Guest on May-14-2020

Browse Popular Code Answers by Language