3 ms·
Any recommendations for a web framework in clojure? I played around with Noir for a while but it seems like that project is abandoned now? What's the Sinatra/Fl
by kreek 14y ago
Any recommendations for a web framework in clojure? I played around with Noir for a while but it seems like that project is abandoned now? What's the Sinatra/Flash of Clojure?
- DigitalJack 14y agoCompojure, Ring, and Enlive or Hiccup are a pretty common stack.
- adambard 14y agoIt should be noted that Clojurers are very much about having composable libraries with narrow applicability. In Sinatra or Flask, you get a server (interface), a routing syntax, and built-in templating. In Clojure, you have Compojure, which handles routing, Ring, a server abstraction for requests, and responses, and the templating library of your choice. (I've used Hiccup and Enlive, as well as Mustache and Markdown). You're responsible for gluing them together, which is really not too hard given the power of the language to create abstractions on the fly. This results in slightly more code, but also makes it much easier to replace or augment any one component.
- weavejester 14y agoTo be fair to Sinatra, it uses Rack underneath, and farms out templating to different libraries. It's certainly more of a framework than Compojure is, but it's not monolithic by any means.
- swah 14y agoIn one particualr website, it was much simpler when I removed Compojure. I remember thinking that was pretty cool. (Seeing clearly what Compojure did and dropping it in favor of a simple hashtable).
- tensor 14y agoThis is currently one of the best sites explaining the clojure web stack: http://www.luminusweb.net/ http://www.luminusweb.net/ There isn't really a single framework, rather you can pick and choose your components depending on your needs or preferences.