setState hook not updating - though prevState shows correct value

前端 未结 0 1078
终归单人心
终归单人心 2020-12-31 06:10

I\'m using the state variable to keep track of my previous state.

The animation works (without index), but when I do

const [index, setIndex] = useState         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题