react-intersection-observer-hook
react-intersection-observer-hook copied to clipboard
Dealing with multiple child refs
Hi, thanks for creating this!
So I want to track a list of items (chat messages in an infinite scrolling list) in a custom scrollable div. If I understand correctly, this means I should use rootRef for the parent. However, since I have multiple children, I need a ref for every chilld, but only one for the parent. Does this library support this? I tried setting the root in the options (passing the parentRef), but for some reason that does not work.
Exactly same problem/situation here.