Hey! So I'm trying to get current cljs, piggieback and weasel running using boot-cljs-repl. And it does one interesting thing: it writes port for the running server in a .cljs file, which is then read by a client, which then connects to a server.
But current version of weasel started blocking (using server/wait-for-client), so boot-cljs-repl never gets control back, which means it can't write port to the file (if the port was not supplied - and chosen randomly by http-kit), which means client never connects - so that's a dead end. :)
I was thinking about solution and what came to my mind is some kind of init function, passed as an option to websocket/repl-env function. Maybe with a different name, but just called before server/wait-for-client function here. What do you think?
Hey! So I'm trying to get current cljs, piggieback and weasel running using boot-cljs-repl. And it does one interesting thing: it writes port for the running server in a .cljs file, which is then read by a client, which then connects to a server.
But current version of weasel started blocking (using
server/wait-for-client
), so boot-cljs-repl never gets control back, which means it can't write port to the file (if the port was not supplied - and chosen randomly by http-kit), which means client never connects - so that's a dead end. :)I was thinking about solution and what came to my mind is some kind of
init
function, passed as an option towebsocket/repl-env
function. Maybe with a different name, but just called beforeserver/wait-for-client
function here. What do you think?