Last active
August 15, 2019 12:53
-
-
Save kaue-silva-ifood/2a64287e78d82e3c69843686ed758e2d to your computer and use it in GitHub Desktop.
Initial Application.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example | |
import io.ktor.application.* | |
import io.ktor.http.* | |
import io.ktor.response.* | |
import io.ktor.routing.* | |
import io.ktor.server.engine.* | |
import io.ktor.server.netty.* | |
fun main(args: Array<String>) { | |
embeddedServer(Netty, 8080) { | |
routing { | |
get("/") { | |
call.respondText("Hello, world!", ContentType.Text.Html) | |
} | |
} | |
}.start(wait = true) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment