diff options
| author | nsfisis <nsfisis@gmail.com> | 2024-07-21 16:13:58 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2024-07-21 16:13:58 +0900 |
| commit | a46f583437e9b66ebec6fa22e27567a71b17b497 (patch) | |
| tree | f375449ee38de9701637fbe77c79111da9f76307 /backend/main.go | |
| parent | 877c19ecbb2425d756f3cbafb1cf52f69279e92d (diff) | |
| download | iosdc-japan-2024-albatross-a46f583437e9b66ebec6fa22e27567a71b17b497.tar.gz iosdc-japan-2024-albatross-a46f583437e9b66ebec6fa22e27567a71b17b497.tar.zst iosdc-japan-2024-albatross-a46f583437e9b66ebec6fa22e27567a71b17b497.zip | |
react router
Diffstat (limited to 'backend/main.go')
| -rw-r--r-- | backend/main.go | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/backend/main.go b/backend/main.go index 68df25b..5661ed6 100644 --- a/backend/main.go +++ b/backend/main.go @@ -158,7 +158,7 @@ func main() { server := http.NewServeMux() - server.HandleFunc("GET /js/", func(w http.ResponseWriter, r *http.Request) { + server.HandleFunc("GET /assets/", func(w http.ResponseWriter, r *http.Request) { http.ServeFile(w, r, "./public"+r.URL.Path) }) @@ -167,7 +167,7 @@ func main() { }) server.HandleFunc("GET /golf/{$}", func(w http.ResponseWriter, r *http.Request) { - http.ServeFile(w, r, "./public/golf/index.html") + http.ServeFile(w, r, "./public/index.html") }) server.HandleFunc("POST /golf/{$}", func(w http.ResponseWriter, r *http.Request) { @@ -175,7 +175,7 @@ func main() { }) server.HandleFunc("GET /golf/{gameId}/watch/{$}", func(w http.ResponseWriter, r *http.Request) { - http.ServeFile(w, r, "./public/golf/watch.html") + http.ServeFile(w, r, "./public/index.html") }) server.HandleFunc("GET /sock/golf/{gameId}/watch/{$}", func(w http.ResponseWriter, r *http.Request) { @@ -200,7 +200,7 @@ func main() { }) server.HandleFunc("GET /golf/{gameId}/{team}/{$}", func(w http.ResponseWriter, r *http.Request) { - http.ServeFile(w, r, "./public/golf/game.html") + http.ServeFile(w, r, "./public/index.html") }) server.HandleFunc("GET /sock/golf/{gameId}/{team}/{$}", func(w http.ResponseWriter, r *http.Request) { @@ -226,7 +226,7 @@ func main() { }) server.HandleFunc("GET /race/{$}", func(w http.ResponseWriter, r *http.Request) { - http.ServeFile(w, r, "./public/race/index.html") + http.ServeFile(w, r, "./public/index.html") }) server.HandleFunc("POST /race/{$}", func(w http.ResponseWriter, r *http.Request) { @@ -234,7 +234,7 @@ func main() { }) server.HandleFunc("GET /race/{gameId}/watch/{$}", func(w http.ResponseWriter, r *http.Request) { - http.ServeFile(w, r, "./public/race/watch.html") + http.ServeFile(w, r, "./public/index.html") }) server.HandleFunc("GET /sock/race/{gameId}/watch/{$}", func(w http.ResponseWriter, r *http.Request) { @@ -242,7 +242,7 @@ func main() { }) server.HandleFunc("GET /race/{gameId}/{team}/{$}", func(w http.ResponseWriter, r *http.Request) { - http.ServeFile(w, r, "./public/race/game.html") + http.ServeFile(w, r, "./public/index.html") }) server.HandleFunc("GET /sock/race/{gameId}/{team}/{$}", func(w http.ResponseWriter, r *http.Request) { |
