no 404 on refresh

This commit is contained in:
Will Freeman committed 2024-10-03 19:22:17 -05:00
1 parent 7424cb83bb
commit e32edaf439
21 files changed
+223 -62

No files matched your search

@@ -70,9 +70,12 @@ object ShotgunServer {
)
}
val spaRoutes = pathSingleSlash {
val spaRoutes = pathEndOrSingleSlash {
getFromFile("../webapp/dist/index.html")
} ~ getFromDirectory("../webapp/dist")
} ~ getFromDirectory("../webapp/dist") ~
path(Remaining) { _ =>
getFromFile("../webapp/dist/index.html")
}
val routes = handleRejections(rejectionHandler) {
cors(corsSettings) {