One of my apps is still on Blaze, and I am trying to implement an endless scroll feature there. So, I initially get about 50 elements, then, once the user scrolls down, another 30 elements are being fetched and so on. This is done using a reactive variable.
I noticed that Blaze shows a quite inconsistent rendering behaviour. Most of the times, after setting the reactive var to a new set of elements, rendering is pretty fast (about 150ms). But sometimes, it takes ages (1-2s) until Blaze’s renderer actually reacts on the changed reactive var, by running the helper that actually retrieves the new value. This leads to a quite wonky user experience.
I am wondering what is causing these huge delays, and if there’s any way of speeding this up?
Another thing I noticed is that the helper gets twice on every update. I don’t see any reason for this, as the reactive var is only changed once, and the helper does not depend on any other reactive source. Any ideas what may cause this?