hooks icon indicating copy to clipboard operation
hooks copied to clipboard

`useMap` and `useSet` don't trigger component render after adding an even amount of items

Open AlexKrupko opened this issue 2 years ago • 0 comments

Hi there, useMap and useSet hooks don't trigger component render after adding an even amount of items. You can find a code example here - https://codesandbox.io/s/unruffled-flower-kh57rp?file=/src/App.js This happens because of using boolean value in the useForceUpdate hook which is used to trigger rendering in both useMap and useSet.

AlexKrupko avatar Jun 25 '23 18:06 AlexKrupko