Created
January 31, 2024 12:22
-
-
Save marcinzh/9a0db95e4255d6279458aef287a97c99 to your computer and use it in GitHub Desktop.
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
//> using scala "3.3.1" | |
//> using dep "io.github.marcinzh::enterprise-core:0.2.0" | |
package examples | |
import turbolift.Extensions._ | |
import enterprise.Response | |
import enterprise.server.{Server, Config} | |
@main def ex01 = | |
Server.serve: | |
Response.text("Live long and prosper").pure_!! | |
.handleWith: | |
Server.undertow &&&! | |
Config.localhost(9000).toHandler | |
.unsafeRunST |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment