How did I miss that??!! I must have read through those docs a million times. Thank you so much for posting.
On Friday, March 22, 2019 at 8:11:57 AM UTC-6, Kasper Timm Hansen wrote: > > Hey Adam, > > That’s already possible. See the Collection Caching section here: > https://api.rubyonrails.org/classes/ActionView/Helpers/CacheHelper.html#method-i-cache > > <%= render partial: 'projects/project', collection: @projects, cached: -> > project { [ project, current_user ] } %> > > > -- > Kasper > > On 15 Mar 2019, at 22.48, Adam Stockland <adamst...@gmail.com > <javascript:>> wrote: > > Not sure if this is a quality idea, or not. When rendering a collection, > could a custom cache key be generated using the object and any locals being > passed? > Example: including current_user in the collection cache key > > > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Core" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to rubyonrails-co...@googlegroups.com <javascript:>. > To post to this group, send email to rubyonra...@googlegroups.com > <javascript:>. > Visit this group at https://groups.google.com/group/rubyonrails-core. > For more options, visit https://groups.google.com/d/optout. > > > -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-core+unsubscr...@googlegroups.com. To post to this group, send email to rubyonrails-core@googlegroups.com. Visit this group at https://groups.google.com/group/rubyonrails-core. For more options, visit https://groups.google.com/d/optout.