summaryrefslogtreecommitdiffstats
path: root/blog
diff options
context:
space:
mode:
Diffstat (limited to 'blog')
-rw-r--r--blog/_includes/head.html1
-rw-r--r--blog/_includes/opengraph.html14
2 files changed, 15 insertions, 0 deletions
diff --git a/blog/_includes/head.html b/blog/_includes/head.html
index 1d66aa8..e345ae5 100644
--- a/blog/_includes/head.html
+++ b/blog/_includes/head.html
@@ -9,6 +9,7 @@
{% endif %}
</title>
<meta name="description" content="{{ site.description }}">
+ {% include opengraph.html %}
<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.baseurl_root | prepend: site.url }}">
{% stylesheet main %}
</head>
diff --git a/blog/_includes/opengraph.html b/blog/_includes/opengraph.html
new file mode 100644
index 0000000..46b099a
--- /dev/null
+++ b/blog/_includes/opengraph.html
@@ -0,0 +1,14 @@
+{% if page.title %}
+ <meta property="og:title" content="{{ page.title }}">
+{% endif %}
+<meta property="og:type" content="article">
+<meta property="og:url" content="{{ page.url | prepend: site.baseurl }}">
+<meta property="og:site_name" content="{{ site.title }}">
+{% if page.excerpt %}
+ <meta property="og:description" content="{{ page.excerpt | strip_html }}">
+{% else %}
+ <meta property="og:description" content="{{ site.description }}">
+{% endif %}
+{% if page.page-image %}
+ <meta property="og:image" content="{{ page.page-image | prepend: site.baseurl }}">
+{% endif %}