Web Development in Clojure
Compojure is an open source web framework for the Clojure programming language. It is compatible with the Ring specification.
Like Clojure, it favours a functional approach, with little to no side-effects. Compojure is also designed to be concise, simple and explicit.
Here's a basic "hello world" example:
1.
(
defroutes
greetings
2.
(
GET
"/"
3.
(
html
[
:h1
"Hello World"
]
)
)
4.
(
ANY
"*"
5.
(
page-not-found
)
)
)
More examples of Compojure syntax can be found in the documentation, or you can grab the latest Compojure builds from builds from the download section.