Created
March 5, 2018 21:12
-
-
Save arichiardi/c48266457981dd9d47bc8c541fb4b32b to your computer and use it in GitHub Desktop.
Dump the Clojure :npm-deps index
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
clojure -e "(require '[cljs.closure :as cc] '[clojure.pprint :refer [pprint]]) (pprint (cc/index-node-modules-dir $(cat cljsc_opts.edn)))" > npm-deps.edn |
the equivalent works in lumo
as well:
lumo -sfK -e "(require '[lumo.closure :as cc] '[clojure.pprint :refer [pprint]]) (pprint (cc/index-node-modules-dir $(cat cljsc_opts.edn)))" > npm-deps.edn
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is the command that will allow you to dump the data structure that ClojureScript uses when processing
:npm-deps
.The map in
cljsc_opts.edn
is basically (not quite but a superset) the compiler option map, it can be empty.Thanks @swannodette for sharing this bit on Slack.