shadow-cljs

https://github.com/thheller/shadow-cljs | https://github.com/sponsors/thheller | https://www.patreon.com/thheller
kiranshila 2020-09-20T15:17:44.049900Z

Do any of the @types/* node modules help with extern business in shadow?

thheller 2020-09-20T15:35:21.050100Z

no

kiranshila 2020-09-20T15:38:47.050500Z

:thumbsup:

theeternalpulse 2020-09-20T20:32:30.057100Z

I've gotten devcards setup with my shadow app but trying to figure out how to run one command to run my app and the devcards on different ports. I'm guessing because they use the same output folder I'd have to change that, but the port seems to be set for both configurations (my main app and devcards)

theeternalpulse 2020-09-21T18:45:49.077800Z

Had to dive deeper, interesting way to handle rendering either devcards or the main app.

Lucy Wang 2020-09-22T14:51:24.093600Z

the compiler option is not necessary if you add the app.devcards ns to the preloads, because preloads are not included in release builds iirc

2020-09-20T21:18:01.058500Z

Hi, I am recently getting errors while working with Shadow-cljs in nREPL. It often happens that after code reloading, the repl gets broken and I am getting error messages from it. Restarting shadow-cljs helps. For instance, just now I am getting this:

@re-frame.db/app-db
=> #object[ReferenceError ReferenceError: re_frame is not defined]

2020-09-20T21:33:17.058800Z

I am frequently getting Timeout while waiting for result.

2020-09-20T21:34:09.059200Z

And shadow-cljs outputs this for instance:

[2020-09-20 23:33:38.961 - WARNING] :shadow.cljs.devtools.server.util/handle-ex - {:msg {:op :cljs-compile, :input {:code "(require '[orgpad.common.util.url :as url])", :ns cljs.user, :repl true}, :include-init true, :call-id 6, :from 52}}
AssertionError Assert failed: (symbol? repl-ns)
        shadow.build.resolve/resolve-repl (resolve.clj:639)
        shadow.build.resolve/resolve-repl (resolve.clj:639)
        shadow.cljs.repl/repl-require (repl.clj:207)
        shadow.cljs.repl/repl-require (repl.clj:187)
        shadow.cljs.repl/process-read-result (repl.clj:514)
        shadow.cljs.repl/process-read-result (repl.clj:494)
        shadow.cljs.repl/process-input (repl.clj:680)
        shadow.cljs.repl/process-input (repl.clj:658)
        shadow.cljs.devtools.server.worker.impl/fn--15155 (impl.clj:755)
        shadow.cljs.devtools.server.worker.impl/fn--15155 (impl.clj:745)
        clojure.lang.MultiFn.invoke (MultiFn.java:234)
        shadow.cljs.devtools.server.util/server-thread/fn--14818/fn--14819/fn--14827 (util.clj:285)

2020-09-20T21:34:35.059400Z

as response for running (require '[orgpad.common.util.url :as url])

theeternalpulse 2020-09-20T23:42:23.059600Z

Think I figured it out, just had to make a devcards.html, and output my devcards build to another dir, then just run them both with watch.