Vue-Router Passing Data with Props
When you navigate to the new route programmatically, you should use params
, not props.
self.$router.push({name: 'reading-comprehension', params: {guid:self.userInfo.uniqueID }});
Secondly, in your route definition, you should set the props
property to true.
{name: "reading-comprehension", component: SomeComponent, props: true }
Finally, in your component, you define props
separately from data
and it should be all lower case.
export default { props: ["guid"], data(){ return { } }}