portal

martinklepsch 2023-09-05T14:45:19.070709Z

hello 🙂 Is there a way to close the portal window when the connection is lost? I sometimes restart the hosting process quite often, resulting in lots of portal windows... 😄

practicalli-johnny 2023-09-05T15:20:53.416519Z

I close the browser tab, Ctrl-w if I forget to call portal close before closing the repl.

👍 1
djblue 2023-09-05T17:07:03.551549Z

For the jvm, I do

(.addShutdownHook
 (Runtime/getRuntime)
 (Thread. (fn [] (portal.api/close))))

🚀 1
martinklepsch 2023-09-05T20:23:45.120669Z

ah that's a good idea, I think I should be able to do something like that in node

martinklepsch 2023-09-05T20:26:44.253519Z

Is portal and nbb a supported combination? I'm getting errors when requiring portal.api due to clojure.datafy missing

djblue 2023-09-05T20:28:33.047599Z

I think the main thing I got working for nbb was the remote client

djblue 2023-09-05T20:29:10.825379Z

I think getting all the portal runtime code working wouldn't be too much work, just haven't looked into it yet.

djblue 2023-09-05T20:30:01.534709Z

The main issues are adding some of the missing pieces Portal expects to find in a Clojure dialect or removing those features as hard dependencies.