News for hackers. Stuff that matters.

Which Lisp Variant for Web Dev?

I would like to make a foray into web development using LISP, but am at an impasse: Which variant do I choose? What are the relative merits / resources available for CommonLisp, Scheme, and Clojure?
( 13 comments | 23 points | on HN )
Re:Which Lisp Variant for Web Dev? by evanrmurphy on Monday December 13, 2010 @01:59PM (#2001557)
As JavaScript becomes increasingly ubiquitious thanks to budding frameworks like node.js, the lisp->javascript compilers start to look more interesting. Parenscript [1], Scriptjure [2] and Scheme2Js [3] are the respective projects for Common Lisp, Clojure and Scheme, and they're all relatively mature.

More recently, Jacob Rothstein started Sibilant [4], which I've been collaborating on [5]. The main difference in approach is that we're trying to design a new lisp dialect optimized for the task of writing JavaScript, rather than compiling from an existing lisp dialect that wasn't designed with this purpose in mind. Since it's such a young project, I wouldn't recommend it for production environments now, but you should keep an eye on it if you're interested in this sort of thing.

---

[1] http://common-lisp.net/project/parenscript/

[2] http://www-sop.inria.fr/indes/scheme2js/

[3] https://github.com/arohner/scriptjure

[4] https://github.com/jbr/sibilant

[5] https://github.com/evanrmurphy/sibilant

Re:Which Lisp Variant for Web Dev? by jbr on Tuesday December 14, 2010 @04:45PM (#2005844)
Thanks, Evan! I actually disagree about production use, with similar reasoning to Travis Swicegood's answer about coffeescript in production [1]. Since sibilant is just a source-to-source compiler, it's as production-ready as Node.js or client-side javascript is. The output javascript from sibilant is fairly plain and readable and encourages a particular subset of javascript's features. The language is under active development, but Node's API is also changing. I've been hacking on sibilant since late June and believe it to be sufficiently expressive, although it can always get better.

---

[1] http://www.quora.com/Should-I-use-CoffeeScript-for-more-than... .

Re:Which Lisp Variant for Web Dev? by revorad on Monday December 13, 2010 @01:33PM (#2001462)
This question is asked quite often on HN. Have you tried to search for old posts? http://searchyc.com

Look out for posts from mahmud, smanek, silentbicycle.

Re:Which Lisp Variant for Web Dev? by beambot on Monday December 13, 2010 @01:48PM (#2001515)
Thanks. Was not familiar with SearchYC.
Re:Which Lisp Variant for Web Dev? by ferostar on Monday December 13, 2010 @01:23PM (#2001424)
You could give Clojure a try, with Ring (an awesome library) and Compojure (a Sinatra-like framework).
Re:Which Lisp Variant for Web Dev? by francoisdevlin on Monday December 13, 2010 @01:54PM (#2001540)
This is an area where JVM interop is really nice, too. You can deploy with well tested & documented web servers.
Re:Which Lisp Variant for Web Dev? by beambot on Monday December 13, 2010 @02:42PM (#2001707)
I'm fairly versed in functional programming and LISP (having grokked PG's "On Lisp"). (Un)fortunately, I have yet to touch Java -- it always conjured images of C/C++, and that was sufficient to keep me at arm's length (I'm a python robotics hacker day-to-day).

My question: How requisite is Java know-how to using Clojure?

Re:Which Lisp Variant for Web Dev? by kaffiene on Monday December 13, 2010 @03:12PM (#2001796)
You need to know what's in the Java libraries if you want to write to the Java libraries. If your code is all self contained, then you don't. So - open a Swing JFrame and you need to know where that is in the API and how to call it.
Re:Which Lisp Variant for Web Dev? by jwr on Monday December 13, 2010 @02:01PM (#2001567)
Clojure if you need to build anything serious. You can't beat its approach to concurrency, easy access to a multitude of Java libraries and the stability and maturity of the JVM as a platform.

Scheme if you want to learn a Lisp and then move on.

I wouldn't suggest Common Lisp (although it pains me to say that, as I've spent a lot of time building webapps with it). It is neither easy to learn nor easy to deploy and maintain in production.

Re:Which Lisp Variant for Web Dev? by evanrmurphy on Monday December 13, 2010 @02:05PM (#2001576)
> Clojure if you need to build anything serious.

Could you please link to some web apps built in Clojure? I really wanted to use Clojure for web development, but because I couldn't find many existing projects, I kind of concluded that if you really need to build anything serious you should be using Rails.

Re:Which Lisp Variant for Web Dev? by nickik on Monday December 13, 2010 @04:22PM (#2002016)
There are not alot jet but consider that clojure is pretty young but there are great projects on the way. There are some pretty new ideas how to do webdev. Intressting times.

the-deadline.appspot.com/ is one example I know off. I know off some other but I don't have the links. A lot of people build front ends in ruby but backends in clojure (the flightcaster system for example).

In Clojure we don't have the all powerful big framework. Witch makes it hard to overlook but very dynamic.

http://www.glenstampoultzis.net/blog/clojure-web-infrastruct...

Re:Which Lisp Variant for Web Dev? by jwr on Wednesday December 22, 2010 @04:49AM (#2030971)
I don't know — but we use it in our startup for a REST-style API and it works great for us.
Re:Which Lisp Variant for Web Dev? by makmanalp on Monday December 13, 2010 @04:23PM (#2002023)
Not really a lisp variant but interesting nonetheless, for any common lisp: http://common-lisp.net/project/cl-weblocks/ http://trac.common-lisp.net/cl-weblocks/wiki/UserManual#Brea...