Live data from Hacker News

Lisp for the Web, Part II

msnyder.info

1–10 of 18 posts

Re: Lisp for the Web, Part II

#2
Great article! The only thing I'd do differently is just serve up the js as a static file instead of using code transformation. That seems likely to break for non-trivial amounts of js.

Re: Lisp for the Web, Part II

#5
post #2

Great article! The only thing I'd do differently is just serve up the js as a static file instead of using code transformation. That seems likely to break for non-trivial amounts of js.

Yeah, Generate the data (JSON) that the javascript will work with, don't generate the javascript. That way we can have easy to serve, easy to cache static javascript.

Re: Lisp for the Web, Part II

#7
I've been hacking together a site using Hunchentoot, Postmodern + PostgreSQL, CL-WHO for HTML generation, and CL-JSON + Backbone.js for client interaction. I'm probably duplicating a lot of functionality that would already be done with Rails or Django but I'm having a lot of fun doing it this way :)

Re: Lisp for the Web, Part II

#8
post #2

Great article! The only thing I'd do differently is just serve up the js as a static file instead of using code transformation. That seems likely to break for non-trivial amounts of js.

Yeah, Generate the data (JSON) that the javascript will work with, don't generate the javascript. That way we can have easy to serve, easy to cache static javascript.

Generated JavaScript can be served and cached just like static .js files. It doesn't have to be embedded in the HTML.

Re: Lisp for the Web, Part II

#9
post #2

Great article! The only thing I'd do differently is just serve up the js as a static file instead of using code transformation. That seems likely to break for non-trivial amounts of js.

I beg to differ. I've used ClojureJS (a Clojure to JavaScript translator) for building a non-trivial web app front end, and the result has not only been robust but also a pleasure to build (from a Lisp programmer's point of view).

[Disclosure: I'm the author of the ClojureJS library]

Re: Lisp for the Web, Part II

#10
post #9
post #2

Great article! The only thing I'd do differently is just serve up the js as a static file instead of using code transformation. That seems likely to break for non-trivial amounts of js.

I beg to differ. I've used ClojureJS (a Clojure to JavaScript translator) for building a non-trivial web app front end, and the result has not only been robust but also a pleasure to build (from a Lisp programmer's point of view). [Disclosure: I'm the author of the ClojureJS library]

Interesting. What's the site, and is the original Clojure source before -> js transformation published somewhere?
Post reply on HN