Put in order · React Native course · Module 4: State and API data

Spread operator in state

Arrange the correct state update preserving immutability:

Items to put in order

  • }))
  • count: prev.count + 1
  • setState(prev =>
  • ({ ...prev,

You can check the correct answer by solving this task in the CodeWorlds game.