aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/lib/action_view/helpers/cache_helper.rb
Commit message (Collapse)AuthorAgeFilesLines
* Fix calling cache helper with a relationLachlan Sylvester2015-08-281-3/+2
|
* Add wildcard template dependencies.Kasper Timm Hansen2015-07-261-1/+13
|
* Support explicit defintion of resouce name for collection caching.Dov Murik2015-07-071-0/+15
| | | | | | | | | | | | | | If a template includes `# Template Collection: ...` anywhere in its source, that name will be used as the cache name for the partial that is rendered for the collection. This allows users to enable collection caching even if the template doesn't start with `<% cache ... do %>`. Moreover, the `# Template Collection: ...` notation is recognized in all template types (and template types other than ERB can define a resource_cache_call_pattern method to allow the `cache ... do` pattern to be recognized too).
* Fix cache issue when different partials use the same collectionRoque Pinel2015-06-281-11/+13
| | | | | | | | | Adds the `virtual_path` option to `cache_fragment_name` so it can be provided when needed. That allows `cache_collection_render` to get the appropriate cache key with the digest generated based on the template and prevent collision with other templates that cache the same collection.
* Tiny documentation edits [ci skip]Robin Dupret2015-06-091-7/+7
|
* Better formatted documents [ci skip]Gourav Tiwari2015-05-081-8/+12
|
* Make ActionMailer #cache helper a no-op, not an exceptionJavan Makhmali2015-04-281-1/+1
|
* Merge pull request #18948 from kaspth/automatic-collection-cachingRafael Mendonça França2015-02-251-0/+31
|\ | | | | Merge multi_fetch_fragments.
| * Collections automatically cache and fetch partials.Kasper Timm Hansen2015-02-211-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Collections can take advantage of `multi_read` if they render one template and their partials begin with a cache call. The cache call must correspond to either what the collections elements are rendered as, or match the inferred name of the partial. So with a notifications/_notification.html.erb template like: ```ruby <% cache notification %> <%# ... %> <% end %> ``` A collection would be able to use `multi_read` if rendered like: ```ruby <%= render @notifications %> <%= render partial: 'notifications/notification', collection: @notifications, as: :notification %> ```
| * Merge multi_fetch_fragments.Kasper Timm Hansen2015-02-201-0/+8
| | | | | | | | | | | | | | | | Makes caching a collection of template partials faster using `read_multi` on the Rails cache store. Some caching implementations have optimized `read_multi` so we don't have to check in the cache store for every template.
* | Fix cache_helper comment ERBAnthony Dmitriyev2015-02-201-2/+2
|/
* Change links to 37signals and svn blog to point to new destinations. [ci skip]Vipul A M2014-04-121-1/+1
|
* Digestor should just rely on the finder to know about the format and the ↵David Heinemeier Hansson2014-03-211-13/+3
| | | | variant -- trying to pass it back in makes a mess of things (oh, and doesnt work)
* Ensure LookupContext in Digestor selects correct variantPiotr Chmolowski2014-03-091-4/+14
| | | | | | | | | | Related to: #14242 #14243 14293 Variants passed to LookupContext#find() seem to be ignored, so I've used the setter instead: `finder.variants = [ variant ]`. I've also added some more test cases for variants. Hopefully this time passing tests will mean it actually works.
* Variants in ActionView::DigestorPiotr Chmolowski2014-03-041-1/+1
| | | | | | | | | | | Take variants into account when calculating template digests in ActionView::Digest. Digestor#digest now takes a hash as an argument to support variants and allow more flexibility in the future. Old-style arguments have been deprecated. Fixes #14242
* fix the typo [ci skip]Rajarshi Das2013-09-021-1/+1
| | | fix the typo newstopics => new topics in action view cache helper
* Refactor cache fragment handling with read/write methodsCarlos Antonio da Silva2013-06-251-6/+6
|
* Move the write portion of fragment_for to its own method to allow for easier ↵Andrew Rove2013-06-251-10/+14
| | | | creation of custom cache methods.
* Move actionpack/lib/action_view* into actionview/libPiotr Sarnacki2013-06-201-0/+196