This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2023-07-25
Channels
- # announcements (1)
- # babashka (15)
- # biff (15)
- # calva (9)
- # cherry (18)
- # cider (43)
- # cljs-dev (1)
- # cljsrn (10)
- # clojure (14)
- # clojure-europe (47)
- # clojurescript (29)
- # clr (5)
- # conjure (1)
- # core-logic (17)
- # datomic (8)
- # emacs (22)
- # fulcro (3)
- # gratitude (1)
- # hoplon (23)
- # humor (1)
- # hyperfiddle (34)
- # jobs (1)
- # kaocha (1)
- # malli (3)
- # nrepl (4)
- # off-topic (18)
- # pathom (12)
- # pedestal (1)
- # polylith (1)
- # portal (17)
- # practicalli (1)
- # re-frame (19)
- # reitit (8)
- # releases (1)
- # rewrite-clj (4)
- # shadow-cljs (15)
- # sql (23)
- # tools-build (4)
How do I start/open the vs-code hosted portal so I can hit it from a shadow-cljs browser environment?
Similar question except I'm using browser instead of node: https://clojurians.slack.com/archives/C0185BFLLSE/p1661026662799939
This was helpful: https://github.com/djblue/portal/blob/098062b5ae23bbdb027654b887f874c0eb7cce88/doc/remote-api.md#usage
Ran across https://github.com/djblue/portal/blob/098062b5ae23bbdb027654b887f874c0eb7cce88/src/portal/shadow/remote.clj which starts a server. Pretty neat. But when I submit
data to the server, where does it go?
https://github.com/djblue/portal/blob/master/src/portal/runtime/jvm/server.clj#L175-L179
Which gets conj'd into this private list https://github.com/djblue/portal/blob/master/src/portal/runtime.cljc#L198-L200 which is the default value portal will inspect
> But when I submit
data to the server, where does it go?
Sorry, I should've been clearer. I recognize that it goes to to the running server, but how do I view it? Can I 'open' a portal that also attaches to the same server that shadow-cljs started?
Cool. Do I need to pass it special options so it associates with the already-started server and doesn't start a new server?
Is that only true of the JVM that runs shadow is the same JVM that I use to call portal.api/open
?
Yup, although you can submit to another jvm which has portal as long as you coordinate which port to use for /submit