Fork me on GitHub
#portal
<
2023-09-05
>
martinklepsch14:09:19

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-johnny15:09:53

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

👍 2
djblue17:09:03

For the jvm, I do

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

🚀 1
martinklepsch20:09:45

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

martinklepsch20:09:44

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

djblue20:09:33

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

djblue20:09:10

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

djblue20:09:01

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.