https://kotlinlang.org logo
#ktor
Title
# ktor
b

bjonnh

03/20/2020, 9:42 PM
Any idea why /index.html isn't served on / using static("/") and returns 404 instead ?
✔️ 1
Copy code
static("/") {
    val path = ::main::class.java.getResource("/client").path
    files(path)
    default("/index.html")
}
(doing /index.html works so the file is here)
Nevermind, I'm keeping that here for others
default takes a localpath not a resolved path
2 Views