2lcc/layouts/partials/head/js.html
2025-02-19 22:21:38 +11:00

13 lines
457 B
HTML

{{- with resources.Get "js/main.js" }}
{{- if eq hugo.Environment "development" }}
{{- with . | js.Build }}
<script src="{{ .RelPermalink }}" type="module"></script>
{{- end }}
{{- else }}
{{- $opts := dict "minify" true }}
{{- with . | js.Build $opts | fingerprint }}
<script src="{{ .RelPermalink }}" integrity="{{- .Data.Integrity }}" crossorigin="anonymous" type="module"></script>
{{- end }}
{{- end }}
{{- end }}