fix: cache page title partial
This commit is contained in:
parent
eb4b646711
commit
bfa512eb6f
2 changed files with 10 additions and 2 deletions
|
@ -86,7 +86,11 @@
|
||||||
</span>
|
</span>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
|
{{- if .File -}}
|
||||||
|
{{- partialCached "text/item-title.html" ( dict "pc" . "sc" $ "class" "item-tile" ) .File.Filename -}}
|
||||||
|
{{- else -}}
|
||||||
{{- partial "text/item-title.html" ( dict "pc" . "sc" $ "class" "item-tile" ) -}}
|
{{- partial "text/item-title.html" ( dict "pc" . "sc" $ "class" "item-tile" ) -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
|
||||||
<p style="display: none;">
|
<p style="display: none;">
|
||||||
|
|
|
@ -40,7 +40,11 @@
|
||||||
|
|
||||||
<div class="article-header__title-wrapper">
|
<div class="article-header__title-wrapper">
|
||||||
<a class="u-url u-uid" style="display: none" href="{{ .pc.Permalink }}"></a>
|
<a class="u-url u-uid" style="display: none" href="{{ .pc.Permalink }}"></a>
|
||||||
{{- partialCached "text/item-title.html" ( dict "pc" .pc "sc" .sc "class" "article-header" ) .File.Filename -}}
|
{{- with .pc.File -}}
|
||||||
|
{{- partialCached "text/item-title.html" ( dict "pc" $.pc "sc" $.sc "class" "article-header" ) .Filename -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- partial "text/item-title.html" ( dict "pc" $.pc "sc" $.sc "class" "article-header" ) -}}
|
||||||
|
{{- end -}}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{ with ( .pc.Resources.GetMatch .pc.Params.featured_image ) }}
|
{{ with ( .pc.Resources.GetMatch .pc.Params.featured_image ) }}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue