Reputation: 11780
I'm using the following code to show a component which passes a value 'category'. The category changes based on user interactions. However, once a component is loaded, its data is not changed according to the change of props.
<button @click="selected='new'">Change</button>
<popup :category="selected"></popup>
data() {
return {
selected: 'test'
}
}
Upvotes: 3
Views: 14870