TWITCH TV: Trouble with ASYNC calls/ Promises, Javascript Objects

TWITCH TV: Trouble with ASYNC calls/ Promises, Javascript Objects
0

#1

Link to My Project

Help! I’ve been struggling with the react state in my Twitch Project.

createTwitchList() function not working properly when state updates.
I think that something is going wrong when trying to access the this.state.channelData object.

The object should look something like this:
{
freecodecamp: {
status: “words”,
stream: “undefined”
}
.
.
.
}

However, console.log() prints ‘undefined’ when trying to access data[‘freecodecamp’][‘status’].