opengraph

This commit is contained in:
Pascal Engélibert 2023-10-17 10:27:27 +02:00
parent 5584161f8f
commit 2ea660fc2a
2 changed files with 5 additions and 0 deletions

View File

@ -17,3 +17,4 @@ highlight_code = false
[extra]
sitename = "Librezo"
public_url = "https://librezo.fr"

View File

@ -8,6 +8,10 @@
{% if page.extra.leaflet or section.extra.leaflet %}<link rel="stylesheet" href="/vendor/leaflet/leaflet.css"/>{% endif %}
<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico"/>
<meta name="viewport" content="width=device-width"/>
<meta property="og:title" content="{% if page %}{{ page.title }}{% elif section %}{{ section.title }}{% endif %}"/>
<meta property="og:type" content="website"/>
<meta property="og:url" content="{{ config.extra.public_url | safe }}{% if page %}{{ page.permalink | safe }}{% elif section %}{{section.permalink | safe }}{% endif %}"/>
<meta property="og:image" content="{{ config.extra.public_url | safe }}/img/drawings/accueil.webp"/>
{% if get_env(name="LIBREZO_WEBSITE", default="prod") == "dev" %}<meta name="robots" content="noindex,nofollow"/>{% endif %}
{% block head %}{% endblock head %}
</head>