I am perplexed by the issue that causes my code to jump straight to
'This is empty'
Even though the value of viewDetails[0]
is not empty
fullName() {
return this.updateData?.viewDetails?.mock_name
? this.updateData.viewDetails[0]?.mock_name
: 'This is empty'
},
I anticipate the output to display the content within viewDetails[0]
, which should contain the name of a person, rather than defaulting to This is empty
when viewDetails[0]
actually contains data.