October 2016
Intermediate to advanced
618 pages
10h 44m
English
Codes in Clojure and ClojureScript are almost the same but there are few differences. For instance, libraries provided by Java and JavaScript are quite different. Host environments between JVM and JavaScript runtimes are also different.
Before the version 1.7, we use the cljx plugin to keep compatibility between them. However, it requires a tooling and the style is not clean.
For such a situation, Clojure 1.7 introduced Reader Conditionals are introduced. Reader Conditionals have richer semantics than cljx, such as default expressions and form splicing and no prepossessing.
Using Reader Conditionals, we can share source code among Clojure, ClojureScript, and ClojureCLR. In this recipe, ...
Read now
Unlock full access