Answer the question
In order to leave comments, you need to log in
How to return object property in parent component?
Hello.
I have parent component with data like this
data: {
myObj: {
first: 'Первый',
second: 'Второй'
}
}
<my-component :obj-val="myObj.first">
// внутри поле для смены first
<my-component>
<my-component :obj-val="myObj.second">
// внутри поле для смены second
<my-component>
$emit
. But how do you tell which property of an object it is? Instead of returning the value and the key of the object? Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question