I have just started with react.js and I got a little bit confused with object, accessing, getting values and all that.
I have an object that goes like this:
Array(5) [
0: Object {id:"1",name:"Jack"}
1: Object {id:"2",name:"John"}
2: Object {id:"3",name:"Ben"}
]
Now what I want to is access the second name("John" with it's ID). I already have its ID taken from an text input but I am not sure how can I get the object values in a loop and then compare the names with X name for example. Can you please help me figure this out?