- I've been searching everywhere for a solution to this question but haven't had any luck.
Recently, I came across an observable array that only has one entry:
https://i.sstatic.net/Op0wB.png
This single entry is stored in self.user()
POSData.Users.getByEmail(sEmail)
.then(data => {
//console.log(data)
self.user.push(data);
})
Now, my goal is to extract specific values and assign them to their own observables, but I'm facing a roadblock.
I've attempted the following code snippet to access the firstName...
console.dir(self.user());
//console.log(self.user()[0].data.firstName());
//console.log(self.user().firstName());
//console.log(self.user().data.firstName());
//console.log(self.user()[0].data.firstName());
//console.log(self.user().data[1].firstName());
If anyone knows how to navigate deeper into the data structure to find the information I need, please share your insights.
Thank you for taking the time to read through this
Best regards,
John