Skip to content

Commit

Permalink
Add og meta tags
Browse files Browse the repository at this point in the history
  • Loading branch information
camblomquist committed Aug 28, 2023
1 parent 7e35393 commit aae2c11
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
8 changes: 8 additions & 0 deletions templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,14 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta property="og:site_name" content="{{ config.title }}">
{% if current_url %}
<meta property="og:url" content="{{ current_url }}">
{% endif %}
{% block meta %}
<meta property="og:type" content="website">
<meta name="description" property="og:description" content="Assorted ramblings">
{% endblock meta %}
<title>{% block title %}{{ config.title }}{% endblock title %}</title>
<link href="{{ get_url(path='style.css') }}" rel="stylesheet" />
<link rel="icon" href="{{ get_url(path='favicon.ico') }}" />
Expand Down
7 changes: 7 additions & 0 deletions templates/page.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
{% extends "base.html" %}
{% import "macros/icons.html" as icons %}

{% block meta %}

{% endblock meta %}
<meta property="og:type" content="article">
<meta property="og:title" content="{{ page.title }}">
<meta name="description" property="og:description" content="{{ page.description }}">
<meta property="og:article:published_time" content="{{ page.date }}">
{% block title %}
{{ page.title }} - {{ config.title }}
{% endblock title %}
Expand Down

0 comments on commit aae2c11

Please sign in to comment.