cljs.analyzer.api/analyze-file

functionsince v0.0-3208Edit
(analyze-file f)
(analyze-file f opts)
(analyze-file state f opts)

Source docstring:
Given a java.io.File, java.net.URL or a string identifying a resource on the
   classpath attempt to analyze it.

   This function side-effects the ambient compilation environment
   `cljs.env/*compiler*` to aggregate analysis information. opts argument is
   compiler options, if :cache-analysis true will cache analysis to
   ":output-dir/some/ns/foo.cljs.cache.edn". This function does not return a
   meaningful value.
Source code @ clojurescript:src/main/clojure/cljs/analyzer/api.cljc
   (defn analyze-file
     ([f] (analyze-file f nil))
     ([f opts]
      (analyze-file (or (current-state) (empty-state opts)) f opts))
     ([state f opts]
      (env/with-compiler-env state
        (binding [ana/*cljs-warning-handlers* (:warning-handlers opts ana/*cljs-warning-handlers*)]
          (ana/analyze-file f opts)))))