diff options
author | Hylke Visser <htdvisser@gmail.com> | 2015-12-20 18:18:51 +0300 |
---|---|---|
committer | Hylke Visser <htdvisser@gmail.com> | 2015-12-20 18:18:51 +0300 |
commit | ac88db2aecaaf9dd768f53d65947cb5de1d5f460 (patch) | |
tree | 5357b891eff37e76cb9107b490a39071c2836ff8 | |
parent | dcdf7bcbef9c4207a597fb1620c64be7f0da4301 (diff) |
Use description, keywords and author
Works with `description` and `author` from `config.toml`:
```
[params]
description = "Tesla's Awesome Hugo Site"
author = "Nikola Tesla"
```
Works with `description` and `keywords` from frontmatter:
```
description = "spf13-vim is a cross platform distribution of vim plugins and resources for Vim."
keywords = ".vimrc,plugins,spf13-vim,vim"
```
Closes #5
-rw-r--r-- | layouts/partials/header.html | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 205181c..362f6d1 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -2,6 +2,9 @@ <html lang="{{ with .Site.LanguageCode }}{{ . }}{{ else }}en-US{{ end }}"> <head> <meta charset="utf-8"> +<meta name="description" content="{{ if eq .Description "" }}{{ .Site.Params.description }}{{ else }}{{ .Description }}{{ end }}"> +<meta name="keywords" content="{{ .Keywords }}"> +<meta name="author" content="{{ .Site.Params.author }}"> {{ .Hugo.Generator }} <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="/css/style.css" type="text/css"> |