Re:Clojure Socket Prepl Cookbook
by knubie on Saturday March 23, 2019 @03:31PM
(#19471959)
This tool looks really cool, but I've never heard of a prepl, what is it? How is it different from a repl?
[ Parent
| on HN ]
The p in prepl stands for programmable or programs, as in, for programs. If you open up a socket REPL you can connect to it and send code + receive results but they're printed without any structure. String goes in and string comes out.
The prepl wraps all responses in a predictable EDN data structure tools can consume with ease. This is what Conjure is built on. The source and doc for the Clojure prepl is really informative: https://github.com/clojure/clojure/blob/8e7213781a1a45db9668...