This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-08-12
Channels
- # announcements (5)
- # babashka (1)
- # beginners (193)
- # calva (79)
- # cider (18)
- # clara (4)
- # clojure (38)
- # clojure-europe (12)
- # clojure-france (8)
- # clojure-nl (12)
- # clojure-sweden (1)
- # clojure-uk (50)
- # clojurescript (37)
- # conjure (30)
- # cursive (3)
- # data-science (2)
- # datalog (7)
- # datomic (12)
- # events (2)
- # expound (3)
- # figwheel-main (1)
- # fulcro (45)
- # graalvm (1)
- # jobs (1)
- # jobs-discuss (11)
- # luminus (1)
- # malli (5)
- # off-topic (32)
- # reagent (6)
- # reitit (32)
- # shadow-cljs (25)
- # spacemacs (2)
- # sql (22)
- # vim (6)
howdy @thheller! i see this issue is closed: https://github.com/thheller/shadow-cljs/issues/716 did this get fixed and i just need a newer version?
I think so but nobody has ever confirmed so no clue actually. I don't use emacs/cider myself and don't have a clue how to test this 😛
ok, pretty sure it isn't working, but i'll test with the very latest version to be sure 🙂
I am attempting to use the cljs library https://github.com/lifecheq/re-auth0 which wraps the https://github.com/auth0/auth0.js/ library. re-auth0 uses the old cljsjs method of including deps. I followed the instructions https://code.thheller.com/blog/shadow-cljs/2017/11/10/js-dependencies-in-practice.html#migrating-cljsjs by creating a shim. However when shadowcljs runs it complains The required JS dependency "process" is not available, it was required by "node_modules/auth0-js/dist/auth0.min.js"
According to https://github.com/thheller/shadow-cljs/issues/519#issuecomment-508386654 this should be remediated by ensuring shadow-cljs is an app dependency... but it already is in my project (generated with luminus), or so I thought? The line in :dependencies in project.clj is [thheller/shadow-cljs "2.10.17" :scope "provided"]
@ramblurr you need to have the npm shadow-cljs installed in your project. so npm install shadow-cljs
. that brings in the required process polyfill.
thanks @thheller that does it, I added a comment to the linked issue mentioning the distinction
Just switched a pretty old node bundle to shadow-cljs and everything works like a charm. Love having a reliable REPL. Thanks @thheller!
Hi everyone, I hope someone can point me in the right direction. I downloaded the react native expo reagent repo. Them I test it on my phone the app loads as expected but in about 5 to 10 seconds I get this error.
Running application "main" with appParams: {"initialProps":{"exp":{"lastErrors":[{"isFatal":false,"errorMessage":"console.error: \"shadow-cljs - remote-error\", [object Object]","exceptionId":2},{"isFatal":false,"errorMessage":"console.error: \"shadow-cljs - remote-error\", [object Object]","exceptionId":3},{"isFatal":false,"errorMessage":"console.error: \"shadow-cljs - remote-error\", [object Object]","exceptionId":3}],"initialUri":"","manifest":{"env":{},"id":"@anonymous/reagent-expo-f0486819-2cb9-4ab2-ae63-272afd37af81","privacy":"public","assetBundlePatterns":["**/*"],"primaryColor":"#023C69","bundleUrl":"","slug":"reagent-expo","name":"hello-world","icon":"./assets/icon.png","xde":true,"loadedFromCache":false,"splash":{"resizeMode":"contain","backgroundColor":"#ffffff","image":"./assets/splash.png","imageUrl":""},"orientation":"portrait","entryPoint":"./app/index.js","iconUrl":"","isVerified":true,"version":"1.0.0","developer":{"tool":"expo-cli","projectRoot":"/home/rick/Repositories/dca3"},"mainModuleName":"app/index","debuggerHost":"192.168.2.36:19001","logUrl":"","packagerOpts":{"https":false,"dev":true,"lanType":"ip","hostType":"lan","minify":false,"urlRandomness":"84-n8h"},"sdkVersion":"35.0.0","platforms":["ios","android","web"],"hostUri":"192.168.2.36:19000","ios":{"supportsTablet":true},"updates":{"fallbackToCacheTimeout":0}},"shell":false}},"rootTag":81}. __DEV__ === true, development-level warning are ON, performance optimizations are OFF
@rickheere I suspect that its picking the wrong IP to connect to. try running shadow-cljs clj-repl
and then (shadow/get-server-addr)
If I connect the devtools I also get the message a bit more info Failed to connect to localhost/127.0.0.1:9630
you can try :local-ip "192.168.2.36"
in the build config or shadow-cljs watch app -config-merge '{:local-ip "192.168.2.36"}'
Live reloading works but the lifecycle hooks (:after-load, :before-load) are not being called, it even logs explicitly that there is no :after-load hook. I've tried both via metadata and in :devtools. Could there be a sane reason?
its :dev/after-load
in the code? the namespace needs to be actually included in the build too? maybe via :preloads
if its not part of your usual code?
@rickheere can you share (shadow/find-local-addrs)
from the CLJ repl?
shadow.user=> (shadow/find-local-addrs)
Syntax error compiling at (REPL:0:0).
Unable to resolve symbol: f in this context
([#object[java.net.NetworkInterface 0x7d151d89 "name:br-c8e7b746556e (br-c8e7b746556e)"] #object[java.net.Inet4Address 0x789f27e5 "/172.19.0.1"]] [#object[java.net.NetworkInterface 0x1dea0730 "name:wlp2s0 (wlp2s0)"] #object[java.net.Inet4Address 0x7dfe23c2 "/192.168.2.36"]])