You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

baseof.html 2.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <!DOCTYPE html>
  2. <html lang="{{ $.Site.LanguageCode | default "en" }}">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  6. {{/* NOTE: the Site's title, and if there is a page title, that is set too */}}
  7. <title>{{ block "title" . }}{{ with .Params.Title }}{{ . }} | {{ end }}{{ .Site.Title }}{{ end }}</title>
  8. <meta name="viewport" content="width=device-width,minimum-scale=1">
  9. {{ hugo.Generator }}
  10. {{/* NOTE: For Production make sure you add `HUGO_ENV="production"` before your build command */}}
  11. {{ if eq (getenv "HUGO_ENV") "production" | or (eq .Site.Params.env "production") }}
  12. <META NAME="ROBOTS" CONTENT="INDEX, FOLLOW">
  13. {{ else }}
  14. <META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
  15. {{ end }}
  16. {{ $stylesheet := .Site.Data.webpack_assets.app }}
  17. {{ with $stylesheet.css }}
  18. <link href="{{ relURL (printf "%s%s" "dist/" .) }}" rel="stylesheet">
  19. {{ end }}
  20. {{ range .Site.Params.custom_css }}
  21. <link rel="stylesheet" href="{{ relURL (.) }}">
  22. {{ end }}
  23. {{ block "favicon" . }}
  24. {{ partialCached "site-favicon.html" . }}
  25. {{ end }}
  26. {{ if .OutputFormats.Get "RSS" }}
  27. {{ with .OutputFormats.Get "RSS" }}
  28. <link href="{{ .RelPermalink }}" rel="alternate" type="application/rss+xml" title="{{ $.Site.Title }}" />
  29. <link href="{{ .RelPermalink }}" rel="feed" type="application/rss+xml" title="{{ $.Site.Title }}" />
  30. {{ end }}
  31. {{ end }}
  32. {{/* NOTE: These Hugo Internal Templates can be found starting at https://github.com/spf13/hugo/blob/master/tpl/tplimpl/template_embedded.go#L158 */}}
  33. {{- template "_internal/opengraph.html" . -}}
  34. {{- template "_internal/schema.html" . -}}
  35. {{- template "_internal/twitter_cards.html" . -}}
  36. {{ if eq (getenv "HUGO_ENV") "production" | or (eq .Site.Params.env "production") }}
  37. {{ template "_internal/google_analytics_async.html" . }}
  38. {{ end }}
  39. {{ block "head" . }}{{ partial "head-additions.html" }}{{ end }}
  40. </head>
  41. <body class="ma0 {{ $.Param "body_classes" | default "avenir bg-near-white"}}{{ with getenv "HUGO_ENV" }} {{ . }}{{ end }}">
  42. {{ block "header" . }}{{ partial "site-header.html" .}}{{ end }}
  43. <main class="pb7" role="main">
  44. {{ block "main" . }}{{ end }}
  45. </main>
  46. {{ block "footer" . }}{{ partialCached "site-footer.html" . }}{{ end }}
  47. {{ block "scripts" . }}{{ partialCached "site-scripts.html" . (default "" .Params.page_scripts) }}{{ end }}
  48. </body>
  49. </html>