cljs.build.api/build
function | since v0.0-3208 | Edit |
(build opts)
(build source opts)
(build source opts compiler-env)
Source docstring:
Given compiler options, produce runnable JavaScript. An optional source
parameter may be provided.
(defn build
([opts]
(build nil opts))
([source opts]
(build source opts
(or
(ana-api/current-state)
(ana-api/empty-state
(closure/add-externs-sources (dissoc opts :foreign-libs))))))
([source opts compiler-env]
(doseq [[unknown-opt suggested-opt] (util/unknown-opts (set (keys opts)) closure/known-opts)]
(when suggested-opt
(println (str "WARNING: Unknown compiler option '" unknown-opt "'. Did you mean '" suggested-opt "'?"))))
(binding [ana/*cljs-warning-handlers* (:warning-handlers opts ana/*cljs-warning-handlers*)]
(closure/build source opts compiler-env))))