get id vue router code example
Example 1: 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>
Example 2: query params vuejs
http://localhost:8000?name=John&email=john@gmail.com
parameters = this.$route.query
console.log(parameters)
name = this.$route.query.name
console.log(name)