all repos — archie @ 1f47eeb7bedefd8fee4d8bae7072766cfa2219ad

A minimal Hugo Theme

Add support for meta descriptions

The meta description tag is _allegedly_ important for SEO, and it
can improve the page's summary in Google results.
David Wittman dave@wittman.xyz
Sat, 22 May 2021 09:43:57 -0500
commit

1f47eeb7bedefd8fee4d8bae7072766cfa2219ad

parent

11d230652b2f918cd77e2c1f3b53736aa370d65e

1 files changed, 3 insertions(+), 1 deletions(-)

jump to
M layouts/partials/header.htmllayouts/partials/header.html

@@ -14,7 +14,9 @@ <link rel="icon" type="image/png" href={{ .Site.Params.favicon }} />

{{- end -}} <meta name="viewport" content="width=device-width, initial-scale=1"> - + {{- if isset .Site.Params "description" }} + <meta name="description" content="{{ .Site.Params.description }}" /> + {{- end }} <meta property="og:image" content="{{ .Site.Params.og_image }}"/> {{ with .OutputFormats.Get "rss" -}} {{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}