71 lines
2.6 KiB
HTML
71 lines
2.6 KiB
HTML
<head>
|
|
<meta charset="utf-8" />
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
|
|
|
<!-- Title -->
|
|
<title>{{ if not .IsHome }}{{ .Title }} - {{ end }}{{ site.Title }}</title>
|
|
|
|
<!-- Meta -->
|
|
{{ if eq .Kind "page" }}
|
|
<meta name="description" content="{{ .Summary }}" />
|
|
<meta name="author" content="{{ .Params.Author | default site.Author.name }}">
|
|
{{ else }}
|
|
<meta name="description" content="{{ .Params.description }}">
|
|
<meta name="author" content="{{ site.Author.name }}">
|
|
{{ end }}
|
|
|
|
<link rel="preload stylesheet" as="style" href="/styles/main.css">
|
|
{{ if or (eq .Kind "list") (eq .Kind "term") }}
|
|
<link rel="preload stylesheet" as="style" href="/styles/list.css">
|
|
{{ end }}
|
|
{{ if and .IsPage (.Page.Scratch.Get "includes_railroad_diagram") }}
|
|
<link rel="preload stylesheet" as="style" href="{{ `styles/railroad.css` | absURL }}">
|
|
{{ end }}
|
|
{{ range $stylesheet := .Resources.Match "*.css" }}
|
|
<link rel="preload stylesheet" as="style" href="{{ $stylesheet.Permalink }}">
|
|
{{ end }}
|
|
{{ if in (.Site.BaseURL | string) "localhost" }}
|
|
<link rel="preload stylesheet" as="style" href="/styles/development.css">
|
|
{{ end }}
|
|
{{ if .IsPage }}
|
|
<link rel="preload stylesheet" as="style" href="{{ `styles/monokai.css` | absURL }}">
|
|
{{ end }}
|
|
|
|
{{ range $.Scratch.Get "social-list" }}
|
|
<link rel="preload" as="image" href="{{ printf `%s.svg` . | absURL }}">
|
|
{{ end }}
|
|
|
|
<!-- Favicon -->
|
|
<link rel="icon" href="{{ `favicon.ico` | absURL }}">
|
|
<link rel="apple-touch-icon" href="{{ `apple-touch-icon.png` | absURL }}">
|
|
|
|
{{ hugo.Generator }}
|
|
|
|
{{ range .AlternativeOutputFormats }}
|
|
<link rel="{{ .Rel }}" type="{{ .MediaType.Type }}" href="{{ .Permalink }}" title="{{ site.Title }}">
|
|
{{ end }}
|
|
|
|
{{ if and .IsPage (.Page.Scratch.Get "includes_railroad_diagram") }}
|
|
<script defer type="module" src="{{ `scripts/railroad.js` | absURL }}"></script>
|
|
<script defer type="module" src="{{ `scripts/railroad-utils.js` | absURL }}"></script>
|
|
{{ end }}
|
|
|
|
{{ if and .IsPage (.Page.Scratch.Get "includes_p5_sketch") }}
|
|
<script defer src="{{ `scripts/p5-1.4.1.min.js` | absURL }}"></script>
|
|
<script defer src="{{ `scripts/sketch-utils.js` | absURL }}"></script>
|
|
{{ end }}
|
|
|
|
{{ range $script := .Resources.Match "*.js" }}
|
|
<script defer type="module" src="{{ $script.Permalink | relURL }}"></script>
|
|
{{ end }}
|
|
|
|
<!-- Misc -->
|
|
{{ if or hugo.IsProduction (eq site.Params.env "production") }}
|
|
<!---->
|
|
{{ template "_internal/schema.html" . }}
|
|
<!---->
|
|
{{ template "_internal/twitter_cards.html" . }}
|
|
<!---->
|
|
{{ end }}
|
|
</head>
|