Fork me on GitHub
#shadow-cljs
<
2019-12-15
>
thheller09:12:47

@wilkerlucio shadow-cljs doesn't have anything regarding "resources". mostly because its a huge topic and I'm not sure how to do it in a maintainable way thats also extensible enough

vinurs12:12:13

when use luminus with

lein new luminus test +reagent +shadow-cljs
then use
lein shadow release app
it output the errors
IllegalArgumentException: No matching field found: getSourceName for class com.google.javascript.jscomp.JSError
        clojure.lang.Reflector.getInstanceField (Reflector.java:397)
        clojure.lang.Reflector.invokeNoArgInstanceMember (Reflector.java:440)
        shadow.build.closure/js-error-xf/fn--23982 (closure.clj:536)
        clojure.core/map/fn--5862/fn--5863 (core.clj:2742)
        clojure.core.protocols/iter-reduce (protocols.clj:49)
        clojure.core.protocols/fn--8140 (protocols.clj:75)
        clojure.core.protocols/fn--8140 (protocols.clj:75)
        clojure.core.protocols/fn--8088/G--8083--8101 (protocols.clj:13)
        clojure.core/transduce (core.clj:6884)
        clojure.core/into (core.clj:6899)
        clojure.core/into (core.clj:6887)
        shadow.build.closure/log-warnings (closure.clj:1081)
        shadow.build.closure/log-warnings (closure.clj:1077)
        shadow.build.closure/log-warnings (closure.clj:1079)
        shadow.build.closure/log-warnings (closure.clj:1077)
        shadow.build.closure/optimize/fn--24199 (closure.clj:1185)
        shadow.build.closure/optimize (closure.clj:1170)
        shadow.build.closure/optimize (closure.clj:1161)
        shadow.build.api/optimize (api.clj:268)
        shadow.build.api/optimize (api.clj:262)
        shadow.build/optimize (build.clj:411)
        shadow.build/optimize (build.clj:403)
        shadow.cljs.devtools.api/release* (api.clj:350)
        shadow.cljs.devtools.api/release* (api.clj:336)
        shadow.cljs.devtools.cli/do-build-command (cli.clj:29)
        shadow.cljs.devtools.cli/do-build-command (cli.clj:26)
        shadow.cljs.devtools.cli/do-build-commands (cli.clj:51)
        shadow.cljs.devtools.cli/do-build-commands (cli.clj:40)
        shadow.cljs.devtools.cli/main/body-fn--28515--auto----29104 (cli.clj:168)
        shadow.cljs.devtools.cli/main (cli.clj:167)
        shadow.cljs.devtools.cli/main (cli.clj:134)
        clojure.core/apply (core.clj:669)
        clojure.core/apply (core.clj:660)
        shadow.cljs.devtools.cli/-main (cli.clj:221)
        shadow.cljs.devtools.cli/-main (cli.clj:219)
        clojure.lang.Var.invoke (Var.java:388)
        user/eval12549 (form-init10468658607384081452.clj:1)
        user/eval12549 (form-init10468658607384081452.clj:1)
        clojure.lang.Compiler.eval (Compiler.java:7177)
        clojure.lang.Compiler.eval (Compiler.java:7167)
        clojure.lang.Compiler.load (Compiler.java:7636)
        clojure.lang.Compiler.loadFile (Compiler.java:7574)
        clojure.main/load-script (main.clj:475)
        clojure.main/init-opt (main.clj:477)
        clojure.main/init-opt (main.clj:477)
        clojure.main/initialize (main.clj:508)
        clojure.main/null-opt (main.clj:542)
        clojure.main/null-opt (main.clj:539)
        clojure.main/main (main.clj:664)
        clojure.main/main (main.clj:616)
        clojure.lang.Var.applyTo (Var.java:705)
        clojure.main.main (main.java:40)
how to debug this error?

thheller12:12:47

@haiyuan.vinurs thats a dependency conflict on the closuer-compiler version

thheller12:12:16

prefer using shadow-cljs.edn only so you don't have to deal with this ...

vinurs12:12:00

ok, let me try it

thheller15:12:38

its CLJ only so no

tianshu16:12:21

is that arborist not try to do the same like svelte is because wanna use arbitrary clojure code instead of dsl like svelte?

thheller16:12:50

can't say really. the mutable style svelte uses doesn't really fit too well into CLJS

thheller16:12:04

I'm just experimenting after all

tianshu17:12:01

I looked at the compiled code of svelte, looks like it just simply recalculate all the variables in a component(in a function called instance), looks like it doesn't distinguish which variable is used by which node, will it really fast?