1 Matching Annotations
  1. Jan 2021
    1. Now for the record, there is one way to fix the code above without useReducer. You may remember that you can pass a function to the updater function useState gives you. When you do this, that function will be passed the current state value. We can utilize this to clear out our dependency array without having to use useReducer.

      this is unclear