Fork me on GitHub
#hyperfiddle
<
2022-06-28
>
Richie01:06:53

Sorry, how do I run a photon demo? Geoffrey walked me through the code today but I only remember running cider-jack-in-clj and picking clojure-cli. Now when I do that in user.demo-1-healthcheck and eval

#?(:clj (user/browser-main! `main))
it says
shadow-cljs has not been started yet!

Dustin Getz01:06:39

src-dev/user.clj (also see user.cljs)

Richie11:06:58

Ok, I'm able to run the demos by running user/main and then running user/browser-main! main for each demo. I copied a demo into scratch and changed the namespace to match. Running (user/browser-main! main) stops the old running demo but doesn't start anything new. File is at photon/scratch/richie/seven_guis/core.cljc ns is richie.seven-guis.core and I changed the ns in :require-macros to match. No other changes.

Richie11:06:41

The photon-starter-app says

Encountered error when macroexpanding hyperfiddle.photon/main.
Failed to resolve macro expander
Thanks!

Dustin Getz12:06:48

did you :require from user.clis

Dustin Getz12:06:03

src-dev/user.clis

Richie13:06:24

Oh, thanks.

Dustin Getz13:06:39

dom/node is the new API in the dev branch; did geoffrey onboard you to the dev branch or master?

Richie13:06:27

I have master checked out but we did briefly look at dev. I must have copied over demo from dev. Thanks.

Richie13:06:08

Ok, great. It's working now.

❤️ 1