Chas Emerick - Targeting Clojure & ClojureScript from a Single Codebase
3,800 views · Published 25 March 2014 · 40:11 · Indexed 4 November 2026
Channel: ClojureTV · 2014 · Science & Technology
Clojure and ClojureScript have been cast from the same mold, to the extent that it is possible to write programs (or, parts of programs) that are entirely portable without changes. However, their lineage and target runtimes necessitate some differences, and others arise because of decisions made in ClojureScript informed by the experiences of building and using Clojure for years prior. While relatively minor, these differences can provoke significant pain when building applications targeting both languages / runtimes, including forcing the maintenance of duplicate codebases, and splitting up namespaces and projects to localize language- or runtime-specific code. cljx will be presented as a solution to this difficulty, an implementation of "feature expressions" similar to that found in other lisps. Many applications and libraries have used cljx over the past year to eliminate duplication in their cross-language codebases without impacting downstream users (they only ever see "regular" Clojure and ClojureScript), and without sacrificing development-time conveniences (e.g. cljx's integration with nREPL allows you to load code into either Clojure or ClojureScript REPLs as-is, with the necessary transformations applied on the fly). Real-world usage of cljx in the community will be exhibited, and its use in Clojure and ClojureScript REPLs will be demonstrated.
More from this channel
-
18:41
Fertile Ground, the Roots of Clojure - Michael Fogus
-
39:41
Lisp, Functional Programming, and the State of Flow - Tom Faulhaber
-
39:17
Protocol XIII: Clojure Protocols Explained - Sean Devlin
-
5:23
Aleph: A Framework for AsynchronousCommunication - Zach Tellman
-
26:57
Clojure and Android - Daniel Solano Gomez
-
38:24
Performance in the Wild - Craig Andera
-
41:18
Concurrent Stream Processing - David McNeil
-
42:20
Ousterhout's Dichotomy Isn't (Part 2 of the Simplicity/Power/Focus Series) - Stuart Halloway