Nicht mehr alle Umrechungsdaten in jeder Seite. Hoffentlich auch Fix für Ladereihenfolge der JS Dateien.

This commit is contained in:
2026-05-28 22:48:57 +02:00
parent e16e9e36fd
commit b92168399f
5 changed files with 60 additions and 105 deletions

View File

@@ -1,20 +0,0 @@
{{ $filteredData := dict }}
{{ range $k, $v := hugo.Data }}
{{ $catData := $v }}
{{ if and (eq $v.slug "waehrungen") $v.units }}
{{ $units := partial "available-units.html"
(dict "category" "waehrungen" "units" $v.units) }}
{{ $catData = dict
"conversion_engine" $v.conversion_engine
"name" $v.name
"slug" $v.slug
"units" $units
}}
{{ end }}
{{ $filteredData = merge $filteredData (dict $k $catData) }}
{{ end }}
<script>
// Globale Einheiten-Daten fuer Alpine.js Conversion-Formular
const UNITS_DATA = {{ $filteredData | jsonify | safeJS }};
</script>