Created
September 29, 2010 18:38
-
-
Save raek/603284 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
(ns se.raek.lcug.web-example | |
(:use [net.cgrand.moustache :only [app]] | |
[ring.adapter.jetty :only [run-jetty]])) | |
(def messages (atom ())) | |
(def routes | |
(app | |
[""] "hi!" | |
["hello"] {:get [{:status 200 | |
:headers {"Content-Type" "text/plain"} | |
:body "Hello, world!"}]} | |
["greet" name] {:get ["Hello, " name]})) | |
(defonce server (run-jetty #'routes {:port 9080, :join? false})) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment