Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zwbetz-gh/papercss-hugo-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzwbetz-gh <zwbetz@gmail.com>2021-05-20 04:55:08 +0300
committerzwbetz-gh <zwbetz@gmail.com>2021-05-20 04:55:08 +0300
commit42e03f6f69290cd72e7da329d283f35da6fafb03 (patch)
tree8f2bf22e1f5543db5af008001d631114ff9694d8
parente1d923b860693e59638797c8d4639252b51d9cbb (diff)
meta description
-rw-r--r--layouts/partials/head.html4
1 files changed, 4 insertions, 0 deletions
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
index d31e3be..6b23466 100644
--- a/layouts/partials/head.html
+++ b/layouts/partials/head.html
@@ -10,6 +10,10 @@
{{ with .Site.Params.homeMetaContent }}
<meta name="description" content="{{ . | plainify }}">
{{ end }}
+ {{ else }}
+ {{ $summary := trim (.Summary | plainify | htmlUnescape) "\n\r"
+ | default .Title }}
+ <meta name="description" content="{{ $summary }}">
{{ end }}
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">