React hooks context - how to update context with onclick event handler ? Getting Invalid hook call err when I try

前端 未结 0 1769
南笙
南笙 2021-02-03 17:32

I am trying to update a context with a callback. When I execute the callback its fine, but when I try to update the property inside of it im getting the err Error: Invalid hook

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