Update head.html
enable OG descriptions for all pages if available
This commit is contained in:
parent
88c6850950
commit
52f1fd1cce
|
@ -12,6 +12,18 @@
|
||||||
content="{{site.url}}/images/{{page.path | split: '/' | last | split: '.' | first }}/{{page.image}}"/>
|
content="{{site.url}}/images/{{page.path | split: '/' | last | split: '.' | first }}/{{page.image}}"/>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
{% if page.description %}
|
||||||
|
<meta
|
||||||
|
property="og:description"
|
||||||
|
content="{{page.description}}"
|
||||||
|
/>
|
||||||
|
{% else %}
|
||||||
|
<meta
|
||||||
|
property="og:description"
|
||||||
|
content="{{page.content | markdownify | strip_html | truncate: 100}}"
|
||||||
|
/>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% if page.collection == "posts" %}
|
{% if page.collection == "posts" %}
|
||||||
<meta property="og:type"
|
<meta property="og:type"
|
||||||
content="article"/>
|
content="article"/>
|
||||||
|
@ -24,18 +36,6 @@
|
||||||
<meta property="article:tag" content="{{ tag }}"/>
|
<meta property="article:tag" content="{{ tag }}"/>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
||||||
|
|
||||||
{% if page.description %}
|
|
||||||
<meta
|
|
||||||
property="og:description"
|
|
||||||
content="{{page.description}}"
|
|
||||||
/>
|
|
||||||
{% else %}
|
|
||||||
<meta
|
|
||||||
property="og:description"
|
|
||||||
content="{{page.content | markdownify | strip_html | truncate: 100}}"
|
|
||||||
/>
|
|
||||||
{% endif %}
|
|
||||||
{% else %}
|
{% else %}
|
||||||
<meta property="og:type"
|
<meta property="og:type"
|
||||||
content="website"/>
|
content="website"/>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user