Fork me on GitHub

Hello I started a library that allow you to run npm install without need a node runtime or npm installed. It's a pure-clojure implementation of an interpreter" of package-lock.json that downloads packages from npm registry and untar it into node_modules. Easy as run (npm/install {:path "."}), or with new -T, clj -T:npm install :path '"."' For me, the advantage of this project is allow me to create advanced compiled cljs without need a nodejs runtime inside my docker image. I would like to know from other cljs developers if this is an interesting lib before continue to work on this project.

clojure-spin 3

@souenzzo you should probably make that work based on either package.json or some other kind of config (eg. deps.edn). how would you get a package-lock.json without having npm or node installed in the first place? 😛


Well, the idea is that you will have a commited package-lock.json In your local/dev machine you will still use node/npm/etc it's just to simplify the deploy pipeline


node is also required for some parts of shadow-cljs, so you'll definitely need node for some builds


can you provide an example?!


anything using ESM code in node_modules. it'll run through babel


should be plenty packages doing this nowadays but can't think of one right now