Announcing https://codeberg.org/nathell/indeed, a reformatter / indenter for not-necessarily-valid EDN. I vibe-coded it because I needed it, and am sharing in case someone needs it too. Notably, it’s not written in Clojure. Feedback welcome!
what does this give over changing your example spit to (spit "/tmp/my-data.edn" (with-out-str (clojure.pprint/pprint my-data)))?
that’s probably even better, but I’ve been in situations where re-obtaining indented edn this way was too much of a hassle
Why not in Clojure?
Covered in README. Basically, perf + fast startup
Those can still be achieved in Clojure. Could have used GraalVM for example. But I'm being nosy, just love me some Clojure you know!
https://github.com/willcohen/resource-tracker 0.0.1 — a https://github.com/squint-cljs/squint port of https://github.com/techascent/tech.resource for object lifecycle management in JS.
The https://github.com/squint-cljs/cherry-based alpha1 from two years ago has been updated to actually dispose of objects correctly and has been migrated to squint. It mirrors tech.resource’s API so JS object lifecycles line up with the JVM idiom: stack-scoped tracking, GC-backed tracking via FinalizationRegistry, or a combined first-wins mode. Adds Symbol.dispose / asyncDispose / .close() dispatch for using and plain-JS callers, plus cljc parity tests against tech.resource on the JVM.
npm i resource-tracker · https://github.com/willcohen/resource-tracker