Skip to content

Instantly share code, notes, and snippets.

@purplefox
Created April 4, 2012 17:44
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 purplefox/2304194 to your computer and use it in GitHub Desktop.
Save purplefox/2304194 to your computer and use it in GitHub Desktop.
Ruby folks, what do you prefer:
require "vertx"
Vertx::HttpServer.new.request_handler do |req|
req.response.send_file("index.html")
end.listen(80)
or
Vertx.create_http_server.request_handler do |req|
req.response.send_file("index.html")
end.listen(80)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment