Those are the right values, but I still don’t know why console.log(data[0].id) gives me an error, and of course still confused as of why filter is not returning anything at all.
In case it’s relevant, I’m using routing and passing the props to the Dashboard component:
And you are not wrong my friend, woa this feels like such a noob mistake hahaha facepalm
Thanks, you saved me from something I don’t think I would’ve seen any time soon. Just out of curiosity, does this happen to people? They cannot see simple things like this until they spend hours trying to figure something out, geez…
By the way, why this console.log(data[0].id) gives me an error?
Well, there you go. I was confused too and tried finding a problem haha.
As for the error when consoling data object, try running debugger (just put in “debugger” without quotes somewhere before the return statement) and refresh the page. You’ll get access to a lot of details (you can hover over them, at least in Chrome) and to the function’s scope, you can even use the console in the browser and access that scope.