Fork me on GitHub
#figwheel-main
<
2018-08-11
>
dottedmag14:08:18

Do I need to do anything to have new cljs file picked up by figwheel main?

bhauman14:08:44

@dottedmag funny we did this at the same time

bhauman14:08:06

It needs to be in your require tree

dottedmag14:08:03

@bhauman It's a new file next to existing one, say src/foo/utils.cljs next to src/foo/app.cljs

bhauman14:08:31

@dottedmag yes you need to require it from a file that has already been required

dottedmag14:08:52

So I have added foo.utils to :require, and now Figwheel complains "No such namespace"

dottedmag14:08:40

Oh, I have created the file in wrong directory. Nevermind 🙂

dottedmag14:08:51

Yay, now it works!

dottedmag14:08:09

I should have noticed that CIDER has not supplied the correct name in automatically created (ns) form, but I have seen this feature broken more often than not, so I supposed it was a CIDER breakage, not my mistake.

dottedmag14:08:06

@bhauman clj + Figwheel Main + CIDER is the first cljs setup I have that is not overwhelming, and where it is possible for me to understand what's going on and even correct errors without thrashing the whole project and starting anew.

dottedmag14:08:23

Just wanted to say "thank you".

bhauman14:08:32

Thats great to hear!!!

bhauman14:08:12

I personally love the faster startup times, which makes restarting less of a hassel.

bhauman14:08:50

and yeah clj is a winner in general for simplicity

bhauman14:08:58

@dottedmag have you always used emacs?

dottedmag14:08:35

Yes. Though pre-clj it was always a struggle to understand various exceptions throwing from different processes.

dottedmag14:08:55

You do a cider-jack-in-cljs and you get an exception from ... somewhere?

dottedmag14:08:52

Now at least I see what's being invoked and try to reproduce it without Emacs.

bhauman14:08:12

yeah that's great

bhauman14:08:26

I tried vim fireplace for the first time the other day

bhauman14:08:48

its really too bad that thats how a lot of folks use Clojure

dottedmag14:08:55

Let's drink some (cider?) for Bozhidar's ass-kicking.

bhauman14:08:35

I'm about to start writing docs for integrating figwheel-main with various editors

bhauman14:08:45

I'm glad CIDER is starting to settle, but I'd really like to make sure that its injecting piggieback before I write it up.

dottedmag14:08:26

Should be trivial to do: it already injects a number of dependencies on startup.

bhauman14:08:41

CIDER did it automatically for a while, and it makes a difference in the setup for a newcomer. And its what the docs report as well

dottedmag14:08:03

It still does it for Leiningen.

bhauman14:08:11

so before I point newbies in that direction it kinda needs to work

dottedmag14:08:16

Looks like only Fighweel Main part is missing.

bhauman14:08:48

you mean it only doesn't inject piggieback in figwheel-main's case?

bhauman15:08:53

just released figwheel-main 0.1.6 with a new Scripting API that will let you start background builds and will let you switch REPLs back and forth between different builds

richiardiandrea16:08:38

This is nice, I use the nrepl-select feature of shadow all the time in new buffers. Does it launch/stop node as well for node targets when you switch builds? Or keeps it open? Will definitely try it out

richiardiandrea17:08:40

Ah maybe, I am talking nonsense, the process should be kept around as the repl so that state is preserved (I actually disable automatic reload here 😄)

bhauman19:08:09

Hmmm there is some strange problem in 0.1.6 that is preventing reloads when nREPL is involved 0.1.5 still works

bhauman21:08:14

I've found the problem and have released 0.1.7

🎉 12