Library files: src/my/core.clj - ns requires my.thing src/my/thing.clj - Clojure implementation of my.thing (loaded by Clojure) src/my/thing.cljs - ClojureScript implementation of my.thing (loaded by ClojureScript)
Open ClojureScript question: Is it possible to AOT and publish a library with Clojure .class files that will be loaded when the library is used by Clojure and .cljs files with the same namespace that will be loaded and used by ClojureScript?
- What about non-boolean expressions for things like Clojure version, JDK version, etc? Out of scope. The "compile-if" trick covers many of those (relatively rare) cases already.
JIRA Tickets and patches: