I have difficult problem when I try to print out a value from a textrow in node.js.
The code console.log(data.res[0]);
prints out [ TextRow { username: 'alex' } ]
So to only print out alex in this case should be easy, but I can't seem to figure it out.
I have tried printing it out by these different sorts of code.
console.log(data.res[0].username);
console.log(data.res.username);
console.log(data[0].res.username);
but these attemps either crashes the code, or prints out username as undefined
.
How am I doing wrong in this?