mirror of
https://github.com/swiss/govtech_hackathon_vote_participation_leaderboard.git
synced 2026-08-26 12:34:26 +00:00
Read-only mirror of https://github.com/swiss/govtech_hackathon_vote_participation_leaderboard — Bundeskanzlei. Issues & pull requests at the source.
- JavaScript 76.2%
- CSS 14.2%
- Python 5.6%
- HTML 4%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| assets/cantons | ||
| js | ||
| pitch | ||
| TTS | ||
| .gitignore | ||
| data.json | ||
| index.html | ||
| LICENSE | ||
| README.md | ||
| script.js | ||
| style.css | ||
govtech_hackathon_vote_participation_leaderboard
Architektur Update (Modularisierung)
Das Projekt wurde auf eine modulare Architektur umgestellt, um die Wartbarkeit und Testbarkeit zu verbessern.
- Einstiegspunkt:
js/main.js(wird inindex.htmlalstype="module"geladen). - Module: Alle Logiken für Charts, Daten-Services und State-Management befinden sich im Verzeichnis
js/. - Legacy: Die Datei
script.jsist deprecated (veraltet) und dient nur noch als Referenz. Sie sollte für neue Features nicht mehr verwendet werden.
Data Fetching
A script fetch_data.js is provided to fetch live voter participation data from ld.admin.ch/query and transform it into the format required by the frontend.
To run it:
node fetch_data.js
This will create data/query_results.json (raw) and data/transformed_data.json (formatted).
The frontends have also been updated to fetch this data dynamically.