Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Lisp - Is it good for web programming/applications (interactive) ? The way ruby is ? The way php is?

Is Lisp good for web programming/applications (interactive), the way ruby and php are?

Things to take into consideration would be:

  • Ease of use
  • Deployability
  • Difficulty (especially for a beginner to programming)

(Edit) I was Particularly referring to Common Lisp, after reading Paul Graham's essay. Would be my first programming language. In this regard. Is it suitable to do so ?

I hear that Clojure's macro functionality is not as powerful as Common Lisp's, and that's why I'm trying to learn Clojure. It teaches programming and is very powerful.

like image 288
Wasif Hyder Avatar asked Apr 30 '11 10:04

Wasif Hyder


1 Answers

Lisp is a language family, not a single language. To somewhat answer your question, yes, web frameworks exist for the various Lisp dialects, like UnCommon Web for Common Lisp and PLT Racket (a Scheme dialect) has a tutorial on their web site too:

http://docs.racket-lang.org/continue/

But one Lisp dialect where you'll see quite a lot of web development going on at the moment is Clojure, since it can leverage existing Java libraries and infrastructure. Here's a list of projects, and that's not comprehensive:

  • Hiccup - represent HTML in Clojure
  • Ring - a HTTP abstraction similar to Rack in Ruby
  • Enlive - selector based templating and more
  • ClojureQL - a SQL integration library
  • CongoMongo - a wrapper for MongoDB

There'd be many more, but I think you get the idea. As for Clojure web apps in the wild, the Clojure learning site 4Clojure would be an example and you can check out the source code on GitHub (I occasionally contribute to this):

  • https://www.4clojure.com/
  • https://github.com/dbyrne/4clojure

As you can see there's quite a lot going on in terms of Clojure and web development. It may not always be smooth sailing, but people are working fast at making the experience better. Making use of existing Java infrastructure does have its benefits, like the possibility to deploy to Google App Engine etc.:

http://www.infoq.com/articles/deadline-clojure-appengine

Hope that somewhat answers your question...

like image 176
Michael Kohl Avatar answered Nov 15 '22 21:11

Michael Kohl