mirror of
https://github.com/Smaug123/static-site-pipeline
synced 2025-10-06 08:48:39 +00:00
85 lines
3.2 KiB
HTML
85 lines
3.2 KiB
HTML
<head>
|
|
<title> {{.Site.Params.author}}{{ with .Title }} | {{ . }}{{ end }} </title>
|
|
|
|
<!-- Meta -->
|
|
<meta charset="utf-8">
|
|
{{- hugo.Generator -}}
|
|
<meta name="viewport" content="width=device-width,initial-scale=1,viewport-fit=cover">
|
|
<meta name="description" content="{{ .Site.Params.description }}">
|
|
{{- if .Site.Params.googleSiteVerify }}
|
|
<meta name="google-site-verification" content="{{ .Site.Params.googleSiteVerify }}">
|
|
{{- end -}}
|
|
|
|
<!-- CSS -->
|
|
{{ $style := resources.Get "css/style.css" | resources.Minify | resources.Fingerprint }}
|
|
<link rel="stylesheet"
|
|
href="{{ $style.Permalink }}"
|
|
integrity="{{ $style.Data.Integrity }}"
|
|
crossorigin="anonymous"
|
|
type="text/css">
|
|
{{ if .Params.sidenotes }}
|
|
{{ $style := resources.Get "css/sidenote.css" | resources.Minify | resources.Fingerprint }}
|
|
<link rel="stylesheet"
|
|
href="{{ $style.Permalink }}"
|
|
integrity="{{ $style.Data.Integrity }}"
|
|
crossorigin="anonymous"
|
|
type="text/css">
|
|
{{ end }}
|
|
{{- $css := "" -}}
|
|
{{- range .Site.Params.customCss -}}
|
|
{{ $css := resources.Get . | fingerprint }}
|
|
<link rel="stylesheet"
|
|
href="{{ $css.Permalink }}"
|
|
integrity="{{ $css.Data.Integrity }}"
|
|
crossorigin="anonymous"
|
|
type="text/css">
|
|
{{- end -}}
|
|
<!-- Desired parts of fontawesome have been extracted to fontawesome.css
|
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css"
|
|
integrity="sha512-+4zCK9k+qNFUR5X+cKL9EIR+ZOhtIloNl9GIKS57V1MyNsYpYcUrUeQc9vNfzsWfV28IaLL3i96P9sdNyeRssA=="
|
|
crossorigin="anonymous" />-->
|
|
|
|
<!-- Favicons -->
|
|
<link rel="shortcut icon" href="{{ .Site.Params.favicon | absURL }}favicon.ico" type="image/x-icon">
|
|
|
|
<link rel="canonical" href="{{ .Permalink }}">
|
|
|
|
<!-- RSS -->
|
|
{{ with .OutputFormats.Get "rss" -}}
|
|
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
|
|
{{ end -}}
|
|
|
|
<!-- JavaScript -->
|
|
{{ $anatole := resources.Get "js/anatole-header.js" }}
|
|
{{ $secureJS := $anatole | resources.Minify | resources.Fingerprint }}
|
|
<script src="{{ $secureJS.Permalink }}"
|
|
integrity="{{ $secureJS.Data.Integrity }}"
|
|
crossorigin="anonymous"></script>
|
|
|
|
{{- $js := "" -}}
|
|
{{- range .Site.Params.customJs -}}
|
|
{{- if or (in . "http://") (in . "https://") -}}
|
|
<script src="{{ . | relURL }}"></script>
|
|
{{- else -}}
|
|
{{- $customJS := resources.Get . -}}
|
|
{{- if $customJS -}}
|
|
{{- if eq $js "" -}}
|
|
{{- $js = $customJS -}}
|
|
{{- else -}}
|
|
{{- $js = slice $js $customJS | resources.Concat "js/custom.js" -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
|
|
{{- if ne $js "" -}}
|
|
{{- $secureJS := $js | resources.Minify | resources.Fingerprint -}}
|
|
<script src="{{ $secureJS.Permalink }}"
|
|
integrity="{{ $secureJS.Data.Integrity }}"
|
|
crossorigin="anonymous"></script>
|
|
{{- end -}}
|
|
|
|
<!-- Twitter Cards -->
|
|
{{ template "_internal/twitter_cards.html" . }}
|
|
</head>
|