Fork me on GitHub

Is package.json + build.edn (rather than :npm-deps) now the best place for a cljs library (per to note its js dependencies and a path to a working bundling method, which then assumes that downstream users will just need to be aware that they need to add those for themselves on their own?


CLJS libs that depend on npm libs should note them in deps.cljs


so is it fair to say that the bundle target with aggressive js hinting may solve npm usage and advanced compilation for the final stages of projects, but cljsjs is still a needed step for libraries? i thought i’d finally escaped generating externs!


the webpack guide doesn’t really go into it, but if you assume that people are using the :bundle target, then the idea is you place your libs npm deps in deps.cljs to tell downstream apps/libs to install them. then, use them throughout your lib code the same way it says in the webpack guide


oh. lovely. that’s perfect. thank you so much


this also operates well with shadow-cljs projects too