Fork me on GitHub
#cider
<
2021-05-06
>
mbertheau04:05:13

When I have two cljs repls connected to the current project (one web, one react-native), how do I switch between them? I.e. how do I determine which repl cider-eval-last-sexp goes?

dpsutton04:05:50

it's based on which one last had point in it (the cursor). so focus the one you want and then all forms will be evaluated there

👍 3
yuhan05:05:12

I'm in a .cljs file trying to cider-connect-cljs, but Cider tells me that there's an existing clj repl and I should connect a sibling, so I run cider-connect-sibling-cljs but it throws an error "no cljs REPLs in current session". Am I missing something? That's the whole reason for trying to connect a sibling

yuhan05:05:56

Ok, I figured out that I have to be in a .clj buffer in order to connect a cljs sibling, and vice versa (if the session only has a cljs repl, I have to navigate to a cljs file and then connect-sibling-clj). Is this the right mental model? I find it quite unintuitive, especially if there are no files of the other type at all

dpsutton05:05:49

file a ticket about that. that sounds quite weird

👌 3
bozhidar05:05:45

Agreed. Seems like a bug.

bozhidar05:05:21

At this point the session management code is definitely the most problematic part of CIDER's code.

bozhidar05:05:56

It needs a lot of love.

yuhan06:05:17

Also, is there any indication of errrors when evaluating Clojurescript forms? I'm not expecting full stack traces like with the JVM, just anything to distinguish it from the evaluation returning nil