3 ms·
For what it's worth, I just implemented this on the staging environment of https://www.biglittlepond.com https://www.biglittlepond.com. The one-line `render` ca
by nthj 14y ago
For what it's worth, I just implemented this on the staging environment of https://www.biglittlepond.com https://www.biglittlepond.com. The one-line `render` call for the most recently collected items dropped from ~700 ms to ~50 ms. 25 items per page. This will be going into the production release later this week.
(This doesn't affect every page load, because I was caching the entire rendered view, as well, but for cache-rebuilds when an item is changed or added, this is -stellar-). Thanks, Nate.
- nate 14y agoYay! That's awesome. Thanks for that.
- nthj 14y agoSure! I should note, too, I was already caching each individual item, then pulling in each cache one-by-one. The above improvements were only due to your gem. Also, I submitted a pull request [1] to add support for cache options, like "expires_in: 3.days". That's the only thing I could think to add. This is one of those magic libraries that you're just like, man, did that really happen? Everybody should use this. [1] https://github.com/n8/multi_fetch_fragments/pull/4 https://github.com/n8/multi_fetch_fragments/pull/4