lynaghk / cljx

Write a portable codebase targeting Clojure/ClojureScript

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Code emitted can't be used in user.clj when relying on hooks

jeluard opened this issue · comments

user.clj is loaded before any of the hooks get a chance to be called.

I made some attempts to add other hooks but without success. As user.clj is loaded by Clojure code and not by leiningen it makes things more complex.

I don't think this is a solvable issue; as you say, Clojure itself loads user.clj, long before cljx is loaded.

Do you expect to resolve the problem at all?

Not really, I was wondering if I was missing something. Right now the only option I see is to manually remove user.clj from the classpath, run lein cljx once then reintroduce user.clj.
Not that bad still I'd rather not do it! :)