Merge pull request #19 from RPGillespie6/make_favicon_configurable

Make favicon configurable
This commit is contained in:
Radek Kozieł 2019-03-16 18:00:27 +01:00 committed by GitHub
commit 54e5006109
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View file

@ -81,6 +81,8 @@ paginate = 5
fullWidthTheme = false
# center theme with default width
centerTheme = false
# set a custom favicon (default is a `themeColor` square)
# favicon = "favicon.ico"
[languages]
[languages.en]

View file

@ -16,8 +16,10 @@
<!-- Icons -->
<link rel="apple-touch-icon-precomposed" sizes="144x144" href="{{ "img/apple-touch-icon-144-precomposed.png" | absURL }}">
{{ with $.Site.Params.ThemeColor }}
<link rel="shortcut icon" href="{{ printf "img/favicon/%s.png" . | absURL }}">
{{ if isset $.Site.Params "favicon" }}
<link rel="shortcut icon" href="{{ $.Site.Params.favicon | absURL }}">
{{ else }}
<link rel="shortcut icon" href="{{ printf "img/favicon/%s.png" $.Site.Params.ThemeColor | absURL }}">
{{ end }}
<!-- Twitter Card -->