Add index page and link to share more easily

This commit is contained in:
2025-01-20 10:13:59 +01:00
parent 5668b1cd6a
commit bddae031cc
5 changed files with 53 additions and 6 deletions

View File

@ -22,6 +22,7 @@ func (app *application) routes() http.Handler {
cached := alice.New(app.cacheStatic)
mux.Handle("GET /static/", cached.Then(http.FileServerFS(ui.Files)))
mux.HandleFunc("GET /", app.indexPage)
mux.HandleFunc("GET /election/create", app.createElectionPage)
mux.HandleFunc("GET /election/{id}", app.getElectionPage)