clojurescript why: (def ... is failing whereas (let ... succeeds

2012-02-10 Thread billh2233
I don't understand (def someVar (newInstantiatedGoogFxObject...)). Why does (def someVar (new-goog-fx-object ...)) fail whereas (let [somevar (new-goog-fx-object ...) ] works? I'm trying to define a variable using def and instantiate a new goog.fx.DragDrop, but this clojurescript: (def dragSo

clojure-based non-blocking webserver like Node.js

2011-09-02 Thread billh2233
Is there a clojure-based webserver that uses non-blocking IO like Node.js, or any effort like that being considered? I like Node.js's non-blocking IO for performance reasons, though it is built around a single-threaded model whereas clojure is built around a multi-core/concurrency model. I wonder

array literal syntax

2012-01-10 Thread billh2233
How do I code an array literal in clojurescript that translates to an array literal in javascript? What's the syntax? If I code in clojurescript: ... [22 33] ... it translates to a javascript vector: cljs.core.Vector.fromArray([22,33]) Javascript (fx/Animation) needs an array defining a

I don't understand how to instantiate a closure library object

2012-01-10 Thread billh2233
I'm trying to instantiate a new goog.fx/Animate object, but the constructor doesn't return anything: (:require [goog.fx :as fx]) (let [anim (fx/Animation (array 22 33) (array 44 55) 1000 nil)] "anim:>" # "" # "http://groups.google.com/group/clojure?hl=en