I want to use some plain .js files in my ClojureScript project. I'm building it using lein-cljsbuild and the .js files are standard Google Closure namespaces with proper goog.provide declarations. So basically what I want is to merge them into the compilation sources that goes int the Closure Compiler. Is that possible?
You should be able to add your Closure-aware JS files to :libs
under the :compiler
key in your build specification:
;; in project.clj
:cljsbuild {:builds [{:source-paths [...]
:compiler {:libs ["foo.js"] ; <- add the libs here
...}}]}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With