-
-
Save anildigital/352cf0a463420ea167fb 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 clojurebyexample.core | |
(:use ring.adapter.jetty) | |
(:use ring.middleware.resource) | |
(:use ring.middleware.file) | |
(:use ring.middleware.file-info)) | |
(defn handler [request] | |
{:status 200 | |
:headers {"Content-Type" "text/plain"} | |
:body "Hello Another World"}) | |
;; wrap the handler, to be able to add middleware etc | |
(def app (-> #'handler (wrap-resource "." ))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment