Sophia, in your codepen below you have two set state calls and I understand that the instruction to…
Joshua Jacobson

The example was mostly to illustrate what could happen if you relied on this.state after calling this.setState Yes — the problem could surface by calling this.setState once and then after that call referred to this.state in a way that relied on the data that was changed in the setState call. Does that make sense? I’ll spend some time to come up with another example that illustrates the issue a little better.

Like what you read? Give Sophia Shoemaker a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.