We have a requirement for a VirtualList to be connected to a collection a large number of items. We have a non-trivial renderer for each item and we receive a high frequency of updates to the items from the server.
We are looking for the most efficient way to handle this - when an asynchronous update arrives from the server, we want to update the renderer as quickly as possible, but ideally only if that renderer is in view. For others, as they come into view, we need the renderer to access the most recent data and then receive updates, as they arrive. Conversely, we need to know when not to update a renderer, if it is not in view.
Is there a recommend pattern for achieving the above?
The workaround that I can think of is that you manually keep track of which items are in view by listening to attach and detach events from the rendered components and then use that to filter your events.