mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-14 20:37:55 -05:00
18 lines
678 B
HTML
18 lines
678 B
HTML
|
<!-- scripts -->
|
||
|
{{ $scripts := resources.Get "output/js/app.js" }}
|
||
|
{{ $isDev := eq hugo.Environment "development" }}
|
||
|
{{ if not $isDev }}
|
||
|
{{ $scripts = $scripts | fingerprint }}
|
||
|
{{ end }}
|
||
|
{{ with $scripts }}
|
||
|
{{ if $isDev }}
|
||
|
<script type="text/javascript" src="{{ .RelPermalink }}" crossorigin="anonymous" defer></script>
|
||
|
{{ else }}
|
||
|
<script type="text/javascript" src="{{ .RelPermalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous" defer></script>
|
||
|
{{ end }}
|
||
|
{{ $.Scratch.Set "scripts" . }}
|
||
|
{{end}}
|
||
|
|
||
|
<!-- Place this tag in your head or just before your close body tag. -->
|
||
|
<script async defer src="https://buttons.github.io/buttons.js"></script>
|