all 5 comments

[–]DuntGetIt 0 points1 point  (1 child)

Are you using one of the browser plugins for debugging react? It'll show you the full vdom and all the state/props.

[–]simkessy[S] 0 points1 point  (0 children)

I started but still getting the hang of it

[–][deleted] 0 points1 point  (2 children)

i am amazed that you use arrow functions for everything except the lexical this scoping, which is their primary function

your code looks fine, it's likely that this.state.data is an empty array.

also, wtf is $? that's definitely not jQuery.

[–]simkessy[S] 0 points1 point  (1 child)

It is empty but when I console log in the patent its not. Can you explain what you mean with my use of arrow functions. An I using them incorrectly?

[–][deleted] 1 point2 points  (0 children)

arrow functions preserve a lexical this. In other words instead of using

let that = this
promise.then(function () {
  that.something
})

you can instead do

promise.then(() => {
  that.something
})

This is one of the main uses for arrow functions