Home > OS >  Vue Router : I need To Passing ID to other component but i want make a friendly URL with not Showing
Vue Router : I need To Passing ID to other component but i want make a friendly URL with not Showing

Time:11-12

I want To pass ID of items list via vue router but i Dont want to Show On slug

I want To pass ID of items list via vue router but i Dont want to Show On slugI want To pass ID of items list via vue router but i Dont want to Show On slug

CodePudding user response:

Then for passing the id to the component you should use params:

this.$router.push({name: 'newLocation', params: { foo: "bar"}});

CodePudding user response:

I think u can use meta in vue-router. Just see that https://router.vuejs.org/guide/advanced/meta.html

  • Related