Removed unnecessary math.js load

This commit is contained in:
Francesco 2024-04-24 14:53:00 +02:00
parent e8307cdcac
commit 96d6b7d3f4
4 changed files with 9 additions and 15 deletions

View file

@ -4,6 +4,9 @@
{{ partialCached "head/css.html" . }}
{{ partialCached "head/js.html" . }}
{{ if .Param "math" }}
{{ partialCached "math.html" . }}
{{ end }}
{{ if hugo.IsProduction }}
{{ template "_internal/google_analytics.html" . }}

View file

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