layouts/partials/header.html (view raw)
1<head>
2 <meta charset="utf-8" />
3 <meta http-equiv="X-UA-Compatible" content="IE=edge">
4 {{- $title := ( .Title ) -}}
5 {{- $siteTitle := ( .Site.Title ) -}}
6 {{- if .IsHome -}}
7 <title>{{ $siteTitle }} {{ if isset .Site.Params "subtitle" }}- {{ .Site.Params.Subtitle }}{{ end }} </title>
8 {{- else -}}
9 <title>{{ $title }} - {{ $siteTitle }}</title>
10 {{- end -}}
11
12 {{- if isset .Site.Params "favicon" -}}
13 <link rel="icon" type="image/png" href={{ .Site.Params.favicon }} />
14 {{- end -}}
15
16 <meta name="viewport" content="width=device-width, initial-scale=1">
17 {{ with .OutputFormats.Get "rss" -}}
18 {{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
19 {{ end -}}
20
21 {{- template "_internal/opengraph.html" . -}}
22 {{- template "_internal/twitter_cards.html" . -}}
23 <link href="https://fonts.googleapis.com/css2?family=Fira+Sans&display=swap" rel="stylesheet">
24 <link href="https://fonts.googleapis.com/css?family=Roboto+Mono" rel="stylesheet">
25 <link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/main.css" />
26 {{- range .Site.Params.customJS }}
27 {{- if or (hasPrefix . "http://") (hasPrefix . "https://") }}
28 <script src="{{ . }}"></script>
29 {{- else }}
30 <script src="{{ $.Site.BaseURL }}{{ . }}"></script>
31 {{- end }}
32 {{- end }}
33 {{- end }}
34</head>