I am writing this Web application where I need to visualize filtered, sorted and paginated (on the server) collections through JavaScript (planning on using Isotope to present collections). These collections are dynamic, i.e. they start out with certain items, but their content may change throughout the application's lifetime. Could I implement this functionality by watching a collection on the server through Reactive Extensions for JavaScript? If so, how?
Example
For this particular problem, let's say a collection is rendered in HTML as an element #container
with a child element of class item
for each collection item:
<div id="container">
<div class="item">Item 1</div>
<div class="item">Item 3</div>
</div>
If "Item 2" is then added to the collection and "Item 1" removed from it on the server, JavaScript should react by rendering the updated collection as follows to HTML:
<div id="container">
<div class="item">Item 2</div>
<div class="item">Item 3</div>
</div>
I've created an animated fiddle to demonstrate this sort of scenario. Imagine that the changes to the collection take place on the server, and that the JavaScript simply reacts to it.