I have this JS Object that contains 3 “thread” objects each with different values.
I am trying to get the values from each of the threads. I am able to print the entire json object, but I can’t print individual values from them?
My code:
console.log(threadArray)
returns this in console: (which is perfect)
but when I try to replace "threadArray"
with "threadArray[0].threads[0]["_id"
to get the first thread’s ID, it says it Cannot read unknown value.
Does anybody know why?