diff options
| -rw-r--r-- | README.md | 2 | ||||
| -rw-r--r-- | layouts/partials/head.html | 13 |
2 files changed, 11 insertions, 4 deletions
@@ -17,7 +17,7 @@ theme = "ed" [Params] # Site description. Used in meta description - description = 'Ed is a Jekyll theme designed for textual editors based on minimal computing principles, and focused on legibility and flexibility.' + description = 'Ed is a Hugo theme designed for textual editors based on minimal computing principles, and focused on legibility and flexibility.' # Color scheme. Options: red, orange, magenta, cyan, blue, brown color_scheme = '' ``` diff --git a/layouts/partials/head.html b/layouts/partials/head.html index aa500a1..d4b2a82 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -4,8 +4,10 @@ {{- $title := print .Title -}} {{ if .IsHome }}{{ $title = .Site.Title }}{{ end }} - {{- $description := print .Description -}} - {{ if .IsHome }}{{ $description = .Site.Params.Description }}{{ end }} + {{- $description := print .Params.Description -}} + {{- if or .IsHome (eq .Params.Description "") (not .Params.Description) -}} + {{ $description = .Site.Params.Description }} + {{- end -}} {{- $author := print .Site.Author.name -}} {{- if .Params.author -}}{{ $author = .Params.author }}{{- end -}} @@ -36,7 +38,12 @@ <meta property="og:image" content="{{ $resource_url }}{{ "img/open-graph-logo.png" }}"> <meta property="og:image:width" content="200"> <meta property="og:image:height" content="200"> - {{- /* TODO: add fb:admins and fb:app_id */}} + {{- /* TODO: add fb:admins and fb:app_id */ -}} <!-- meta property="fb:admins" content="" --> <!-- meta property="fb:app_id" content="" --> + + {{- /* TODO: add ability to render 'article' type */ -}} + <meta name="description" content="{{ $description }}"> + <meta property="og:description" content="{{ .Site.Params.Description }}"> + <meta property="og:type" content="website"> </head> |
