> We grabbed a string out of CodeMirror, read it via tools.reader into persistent data structures, passed it into the ClojureScript analyzer, constructed an immutable AST, passed that AST to the compiler, and generated JavaScript source with inline source maps and eval'ed the result. All of this happened inside of your web browser.<p>This is just fantastic! As David himself mentions - this might not be extremely pragmatic but it sure as hell as cool. For me it means that I can get back to writing my web-based Clojure book without being dependent on Himera[0], which although great, is really hard to work with.<p>Awesome work by @swannodette and team!<p>[0] - <a href="https://himera.herokuapp.com/index.html" rel="nofollow">https://himera.herokuapp.com/index.html</a>
The most interesting case for me will be fast starting clojurescripts as the author points out.<p>The one area I have not been happy with is clojure's startup times so hopefully this fixes that going forward.
I have been looking at functional languages for frontend. But, I guess I am one of those people who just can't unsee the parentheses in lisp languages .<p>How does clojurescript compare to elm/purescript ?
I've been wanting to get into ClojureScript (to clean my development practices, etc) but I'm wondering if I need to be a Clojure user. Does it make sense for a Javascript developer to just jump straight to ClojureScript?. I've seen PureScript also.
Does this mean I could use compile and then require clojurescript modules in node? Today I use babel to "transpile" es2015 to es5 and then load those in, could I do something similar with clojurescript?
I'm curious if ClojureScript uses the original clojure library code (eg, drop, take, map...) or re-implements them? I tried to find something in codebase, seems like it uses original.
This is fantastic. It will be a lot easier for noobs to get their feet wet if they can use use the full language without having to fool around with installing a Java toolchain.
How far clojurescript is to be clojure/js. By that I mean how close the JVM and JS are semantically. There were discussions about that few months ago, because of differences deep down between platforms builtin types (js integers, etc). Swannodette also explained that cljs and clj don't share as much code as the team would like. How much clojure code would run correctly as-is on cljs ? Without having to use specific reader conditionals.
Thanks, for all the fish ( by fish I mean awesome code ) @swannodette and team! Can't wait to use Om Next.<p>Also looking forward to seeing some code examples of
Demand-Driven Architecture[0]. Does anyone know of any edifying clojure code examples?<p>[0] <a href="http://www.infoq.com/presentations/domain-driven-architecture" rel="nofollow">http://www.infoq.com/presentations/domain-driven-architectur...</a>
I wonder if one of my favorite libraries for Clojure, Anglican [1] a probabilistic programming language, can be ported to ClojureScript without much effort. One could do amazing things with this.<p>Keep up the good work. Clojure & ClojureScript are awesome.<p>[1] <a href="http://www.robots.ox.ac.uk/~fwood/anglican/" rel="nofollow">http://www.robots.ox.ac.uk/~fwood/anglican/</a>
How does the output of the ClojureScript-compiler-in-ClojureScript compare to the real thing? Do you lose the Google Closure optimizations, and if so, does that mean it isn't a good idea to compile your web app using the ClojureScript compiler running in Node (for example)? It's nice if you can compile ClojureScript on a machine without Java.
This is a huge milestone! I had a problem I was solving with Clojurescript six months ago and having access to the reader would have solved it perfectly, with lisp elegance. Instead I had to make a mess.<p>I think this opens huge computer science educational opportunities. Imagine a LOGO DSL inside your browser. With all the power of cljs. I am very excited!
Wow, this is quite amazing! Does this also mean that we will be able to write macros in Clojurescript?<p>Are there any plans to use mostly the same backend for Clojure and Clojurescript? It seems that since the languages are almost the same, it's only the code generation part that would be different?
I think an article outlining the details behind the non-trivial example, specifically on configuring how library names are resolved and how it can be modified dynamically, would be instructive.