I have a searchContact
method in the helper. I get from the component a list of contacts of type object
and try to convert it to an array
. I want to be able, after conversion, to refer to each element of the array by index and get the value of the "Name" field. But I don't understand why the conversion function .fromEntries ()
is not working? And I am getting the value of the contacts
variable as an [object Object]
.
searchContact : function(component, searchKeyword, helper){
let contacts = Object.fromEntries(component.get('v.contacts'));
...
},