This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # announcements (3)
- # aws (12)
- # babashka (11)
- # beginners (46)
- # calva (10)
- # cider (6)
- # clara (3)
- # cljdoc (6)
- # cljs-dev (13)
- # cljsrn (2)
- # clojure (49)
- # clojure-europe (2)
- # clojure-gamedev (1)
- # clojure-germany (22)
- # clojure-uk (2)
- # clojurescript (28)
- # clojureverse-ops (8)
- # conjure (6)
- # cursive (2)
- # emacs (1)
- # figwheel-main (9)
- # heroku (12)
- # jobs-discuss (1)
- # malli (10)
- # off-topic (1)
- # practicalli (8)
- # re-frame (25)
- # reagent (6)
- # shadow-cljs (24)
- # testing (10)
- # vscode (4)
does anyone know whether or not I can change where
shadow-cljs looks for the local maven
~/.m2 repository? I cant find it in the documentation but I would like for it to use a different path if I could
that works! now is there a way for me to place it as a user configuration like
~/.shadow-cljs/config.edn as written in the users guide but redefine the path of
Why do these two produce so different result? (The top one does not work)
(let [a (. (. firebase -auth) -GoogleAuthProvider)] (-> (a.) (js/console.dir))) => nil (let [a (. (. firebase -auth) -GoogleAuthProvider.)] (-> a (js/console.dir))) => nil
What exactly do you mean by "does not work"?
The difference is that in the below code the last
. is simply ignored. You end up getting that class (assuming it's a class) and not instantiating it.
does not work, as in, produces no instance, the below does. What do you mean with “ignoring the last .”
Where this is used
(defn sign-in [auth-provider opts] (-> (auth) (.signInWithPopup (auth-provider.)) (.then (fn [^js result])) ;don't need to do anything (.catch (fn [e] (if-let [handler (:error-handler opts)] (handler e) (js/alert e)))))) (defn google-sign-in [opts] (sign-in (.. firebase -auth -GoogleAuthProvider) opts))
Try to see the compiled output of
(. (. firebase -auth) -GoogleAuthProvider.) - I'm pretty sure the last dot won't result in
In your example, you have
(auth-provider.) inside. You already have that
new there. If you use the very first statement from the code block in the OP, you'll end up with
new (new GoogleAuthProvider()).
What you first say makes sense now, I have of course swapped the first and second forms in the OP
I have a function that needs to run before the Figwheel server starts. Is there a way to run the function without having to install lein-ring and use its :init key?
I’ve already asked over at #figwheel-main, but am wondering if anybody else is having issues with ClojureScript 1.10.866 when running tests under figwheel main. My tests run fine under figwheel main with ClojureScript 1.10.844 but don’t seem to even compile when using 1.10.866.
2021-05-29 11:38:13.987:INFO::main: Logging initialized @3794ms to org.eclipse.jetty.util.log.StdErrLog [Figwheel:WARNING] Making target directory "target" and re-adding it to the classpath (this only needs to be done when the target directory doesn't exist) [Figwheel] Compiling build fig to "target/public/cljs-out/fig-main.js" [Figwheel] Failed to compile build fig in 0.22 seconds. [Figwheel:WARNING] Compile Exception: Assert failed: Namespace rewrite-clj.node-test does not exist (ana-api/find-ns ns) [Figwheel:SEVERE]
found a similar usage of figwheel in another project that fails in same way, have described in #figwheel-main
interesting. do the tests of figwheel-main proper pass with cljs newest? log an issue with figwheel-main I'd say?
yeah, seems like ClojureScript has changed in some way that figwheel main might need to adapt to.
Wasn’t sure if it was a ClojureScript or figwheel main issue, will start with raising an issue over at figwheel main
Yeah true, probably should, I’ve started with an https://github.com/bhauman/figwheel-main/issues/295.
@lee perhaps it's swallowing an exception here: https://github.com/bhauman/figwheel-main/blob/ead06b94b1b2747ed37e5d8c37118d6e7ae77193/src/figwheel/main/testing.cljc#L82
I wonder if adding some figwheel-main tests to cljs canary tests would be helpful moving forward,