figwheel

general discussion about figwheel, specific discussions in #figwheel-main and #lein-figwheel
2017-10-09T15:01:56.000661Z

On some occasions when using a figwheel CLJS repl with sidecare, emacs, and piggieback I see some mysterious behavior. I try to observe state held in an atom by just evaluating it to let it print. However, it prints nil as if nothing is there. However, if I start prodding at it with details, like keys, count, etc, there are results. There is actually something there. I can see it in the running web page in the browser too. It is as if the CLJS repl has two versions of state and it is able to print both depending on what operations you do. Anything similar ever happen to anyone?

2017-10-09T15:02:44.000420Z

Example would be like:

(-> @my-state :something :foo) ;;= nil
(-> @my-state :something :foo keys) ;;= (:a :b :c)

2017-10-09T15:02:57.000365Z

when no reloading has happened and the browser continues to show me the state with the keys

2017-10-09T15:03:36.000258Z

I also think what comes with this behavior is the repl having a name showing up like

v------- app!{:conn 2} -------
Which isn’t there typically

achikin 2017-10-09T16:21:40.000381Z

Figwheel + cider is dramatically slow for me. Could you please give me some directions to investigate and solve that issue?

lilactown 2017-10-09T23:41:16.000094Z

@achikin same problem here...

lilactown 2017-10-09T23:42:00.000010Z

connecting via lein repl :connect is also quite slow

lilactown 2017-10-09T23:44:06.000123Z

however, starting via lein figwheel it is quite fast

lilactown 2017-10-09T23:47:46.000035Z

yeah, starting a fresh nrepl session:

$ lein repl
user=> (fig-start)
user=> (cljs-repl)
cljs.user=> (println "hello")
"hello" takes about ~3ish seconds to print

lilactown 2017-10-09T23:59:41.000121Z

@mikerod I think I've deduced that the app!{:conn 2} message shows up when you have two browser windows open pointing to the figwheel page