Skip to content

Commit

Permalink
head.html: simplify description
Browse files Browse the repository at this point in the history
  • Loading branch information
XhmikosR committed Mar 29, 2024
1 parent 7d32143 commit d86c019
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions src/layouts/partials/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,18 @@
<link rel="alternate" type="application/rss+xml" href="{{ "/feed.xml" | absURL }}" title="{{ .Site.Title }}">

<title>{{ if .IsHome }}{{ .Site.Title | markdownify }} · {{ .Site.Params.description | markdownify }}{{ else }}{{ .Title | markdownify }} | {{ .Site.Title | markdownify }}{{ end }}</title>
<meta name="description" content="{{ with .Description }}{{ . | markdownify }}{{ else }}{{ if .IsPage }}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . | markdownify }}{{ end }}{{ end }}{{ end }}">
{{- with or .Description .Summary site.Params.Description }}
<meta name="description" content="{{ . | markdownify }}">
{{- end }}
<meta name="generator" content="Hugo {{ hugo.Version }}">
{{ with .Params.robots -}}
{{- with .Params.robots }}
<meta name="robots" content="{{ . }}">
{{- end }}

{{- $colorModeJS := resources.Get "js/color-modes.js" | fingerprint | resources.Copy "/assets/js/color-modes.js" -}}
{{- $colorModeJS := resources.Get "js/color-modes.js" | fingerprint | resources.Copy "/assets/js/color-modes.js" }}
<script src="{{ $colorModeJS.RelPermalink }}"></script>

{{ partial "stylesheet" . }}
{{ partial "favicons" . }}
{{ partial "social" . }}
{{ partial "analytics" . }}
{{ partial "stylesheet" . -}}
{{ partial "favicons" . -}}
{{ partial "social" . -}}
{{ partial "analytics" . -}}

0 comments on commit d86c019

Please sign in to comment.