Beginner Questions: hot loading, objects, chestnut, cursive, etc

I just want a place to store questions about clojurescript I run into and maybe find answers to later (to help other newbies). Any help in answering these questions is 110% welcome.

(T)itle: Escaping from a REPL crash?
(Q)uestion: When I get an error inside a #object the (figwheel.main) REPL crashes and no command seems to escape, so I have to restart the terminal. Is there another way?
(N)otes: Ctrl + C and Ctrl + D do not work.
(A)nswer: ?

(T): Running Chestnut in Cursive
(Q): Has anyone tried setting up a chestnut template in Cursive? It seems like the way IDEA auto saves causes the hot loader to not recognize the changes being made; preventing it loading those changes in the browser.

(T): Understanding the #object data type
(Q): Is there anywhere online I can learn more about this data type? My best guess it that this is a generic javascript object, which I don’t know much about. Further, I’m not sure how to work with #object outside the cheatsheet. The data structures page didn’t seem to have much.

1 Like

Hi @AlbertSnows, welcome to ClojureVerse!

I think you’ll have more luck making a separate post for each question you have, either in #community-center:beginners or in #questions-help:how-to. Try to put in enough relevant information, like what’s your environment, what documentation are you consulting, expected vs observed behavior.

If you get an error message then make sure to copy-paste the actual message, including any output that came before it. If it’s too much to conveniently put in a post then you can put it in a gist.

(T): Running Chestnut in Cursive
(A): Chestnut uses figwheel so it’s more a question of getting these two to work together.
Worst case, using the terminal should work fine.
If you want to use the provided repl to actually take advantage of cursive then make sure you import/make your project correctly with Leiningen.
Cursive & Leiningen:
https://cursive-ide.com/userguide/leiningen.html
Make a local repl also using Lein (profiles: base, dev ?).
Chestnut in particular seems to take a long time to start up. If you run into errors when starting up the repl then you may need to increase the REPL startup timeout in settings.
Hopefully that gets the repl running.
At this point hotloading is hit or miss, but it should work theoretically. If the cljs icon in the bottom left shows up then that’s probably a good sign. For me, reloading the page seems to get hotloading to work again.
Oh and maybe some helpful links:


1 Like