emezeske/lein-cljsbuild — Issue #33: Macros do not appear to work when crossover namespace is granular
Author: kumarshantanu
Created: 2012-02-19 20:14:23+00:00
State: open

**Disclaimer:** This may or may not be an error at all; perhaps just lack of understanding on my part.

In a project I have just a single level namespace, such as `basil.core`, `basil.group`, `basil.render` etc. This is a library and I do not have the liberty to introduce namespaces such as `basil.crossover.foobar` etc. The existing *'advanced'* example in **lein-cljsbuild** shows the usage of macros with an umbrella namespace `example.crossover`; when I use macros similarly in my project they do not seem to work.

The error message I get (in PhantomJS and Firebug) is:
`goog.require could not find: basil.test.test_macros`

`basil.test.test-macros` is a namespace containing CLJS unit-test related macros in a file called `test-cljs/basil/test/test_macros.clj`. This file on its first line has `;*CLJSBUILD-MACRO-FILE*;` to demarcate it as a file containing macros. To have this file picked up as a regular Clojure file I have specified `:extra-classpath-dirs ["test-cljs"]` in `project.clj` file.