I'm using the react-virtualized List within a functional component. It allows you to set a ref for the scorllable list div. I have an onScroll function that is currently capturing the scrollTop position of the scrolled list and storing it in fromPosition I also have a variable storing the toPosition I want to scroll to.
Does anyone have a clean way of enabling the List component to scroll from the fromPosition to the toPosition in a smooth animated way... and triggered when ever a certain piece of state changes (triggerVar)?