million
million copied to clipboard
`useSyncExternalStore` is broken
https://github.com/aidenybai/million/blob/7547fa81ccb0e1a66d5ea4bbba35788190e399bf/packages/react/hooks.ts#L235-L242
I don't think this matches the behavior of React's own useSyncExternalStore
. I believe it should subscribe only the state setter, rather than the [state, stateSetter] returned from useState. Also, it may re-subscribe on every update.