This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-04-22
Channels
- # announcements (1)
- # beginners (179)
- # boot (8)
- # calva (3)
- # cider (4)
- # clara (3)
- # cljdoc (31)
- # clojure (9)
- # clojure-austin (1)
- # clojure-chicago (5)
- # clojure-dev (19)
- # clojure-nl (2)
- # clojure-uk (1)
- # clojurescript (13)
- # core-matrix (1)
- # cursive (86)
- # datascript (2)
- # datomic (13)
- # emacs (3)
- # figwheel-main (1)
- # fulcro (66)
- # off-topic (250)
- # pathom (7)
- # re-frame (19)
- # reitit (5)
- # sql (37)
- # uncomplicate (5)
Hello everybody ! I use Shadow-cljs + Reagent + Firebase authentication for one project and without change, I have suddenly since 2/3 days this error message : TypeError: "'requestAnimationFrame' called on an object that does not implement interface Window" on Firefox ("TypeError: Illegal invocation" on Chrome)
This appears in when I reset a boolean ratom in this function
(defn on-auth-state-changed
[]
(.onAuthStateChanged
(firebase/auth)
(fn
[user]
(if user
(reset! auth? true)
(reset! auth? nil)))))
@admin055 interesting. please try setting :compiler-options {:fn-invoke-direct false}
in your build config.
@thheller Nice ! I'll try this right now, thank you !
@thheller Perfect, the error's gone ! Thx very much for support and your amazing shadow-cljs and more ! 🙂
@thheller Haha 😄 Is this the commit who break something ? https://github.com/thheller/shadow-cljs/commit/0d72e0edb0d8583b965e2ae6042a5aee72190448 If I understand, it's for compilation speed optimization, right ? Src : https://cljs.github.io/api/compiler-options/fn-invoke-direct
yeah. see http://blog.fikesfarm.com/posts/2017-11-16-direct-higher-order-function-calls.html
I tested it in my apps and it worked fine but I'm not using reagent so I missed that
Thx for the link (y)