feat: add favicon from assets folder

This commit is contained in:
Jimmy Cai
2022-06-12 10:50:04 +00:00
committed by GitHub
parent 7d838dc7fd
commit ba3dbc4163
4 changed files with 8 additions and 2 deletions
+6 -1
View File
@@ -18,7 +18,12 @@
{{- end -}}
{{ with .Site.Params.favicon }}
<link rel="shortcut icon" href="{{ . }}" />
{{ $favicon := resources.Get . }}
{{ if $favicon }}
<link rel="shortcut icon" href="{{ $favicon.RelPermalink }}" />
{{ else }}
{{ errorf "Failed loading favicon from %q" . }}
{{ end }}
{{ end }}
{{- template "_internal/google_analytics.html" . -}}