Fork me on GitHub

we don’t treat any keyword specially in our indentation logic


maybe you should show us an example about the nature of your problem?


@nicola: I have the same question does cider switch nrepls automatically for clj/cljs projects based on file extension?

Michael Griffiths15:01:01

@isaac: yes if you have a cljs repl active, it will use that for eval/completion/etc. in .cljs files

Michael Griffiths15:01:21

(as of version 0.10.0 I think)


@cichli: how does cider figure out which repl is cljs?

Michael Griffiths15:01:16

Specifically the track-state middleware is what informs the client of which REPL (technically nREPL session) is CLJ/CLJS -


@cichli: my workflow - start nrepl for clj, start nrepl for cljs and in it start figwheel and start cljs (Piggieback), and it does not work with cider machinery - i.e. only one nrepl active - evals are sent to clj or to cljs and do not depend on file type.


@cichli: my workflow: 1. boot launch clj repl 2. cider connected clj repl (in this case, I can only eval clj code) 3. start-cljs-repl at cider’s clj repl (in this case, I can only eval cljs code) my question: Is there any way make repl can eval both clj and cljs code according the file type?


@isaac: you need two nrepls to work with clj and cljs


two cider client or launch two repl


launch two repls and connect to cider clients


may be i'm wrong


potentially i think it possible to run two repl servers in one java process, but that's another problem

Michael Griffiths15:01:51

You can use cider-create-sibling-cljs-repl (with cider-cljs-lein-repl appropriately set) rather than manually creating two connections (although AFAIK what you’re trying should still work, provided you’re associating the connections with the right project, which I think CIDER does automatically now)

Michael Griffiths15:01:21

You don’t ever need to run two nREPL servers; nREPL supports multiple concurrent sessions


@cichli: follow your guide, I opened two cider connections. but I both clj and cljs file just use the same(the first opened) cider connections.


@cichli i understand my problem, we use reagent template, where both clj & cljs are in the same project.clj