Skip to content

Instantly share code, notes, and snippets.

@grant
Created June 29, 2020 18:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save grant/0954f729e7f95d80daa4c144120f716b to your computer and use it in GitHub Desktop.
Save grant/0954f729e7f95d80daa4c144120f716b to your computer and use it in GitHub Desktop.
Vapor Routes
import Vapor
func routes(_ app: Application) throws {
app.get { req in
return "It works!"
}
app.get("hello") { req -> String in
return "Hello, world!"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment