Cache/Views

{{/* app/views/posts/index.html.tpl */}}
{{ range .posts }}
  {{ cache (cache_key "post-card" .ID .UpdatedAt) "post_card" . }}
{{ end }}
{{/* app/views/posts/show.html.tpl */}}
{{ turbo_frame "post" .post (cache_key "post" .post.ID .post.UpdatedAt) (turbo_src .post.URL) }}
{{/* app/views/posts/_post_card.html.tpl */}}
<article>
  <h2>{{.Title}}</h2>
  <p>{{.Summary}}</p>
</article>