Hi John, I'm the developer of Cursive. I haven't done this myself, but here are details from a Cursive user detailing how he got it working. Others have since tried it and it's worked for them too. I'm planning to add a built-in CLJS REPL but haven't got to it yet.
Here's what Wilker LĂșcio wrote: This is how I got it done (and I'm using it on node-webkit project): > > Add this plugin to your project (plugins, not dependencies): > > [jarohen/simple-brepl "0.1.0"] > > On your main cljs file, add this :require > > [weasel.repl :as ws-repl] > > Also add this at your init point so it connects with the REPL: > > (ws-repl/connect "ws://localhost:9001") > > Setup wise that's all you need. > > After that, start your REPL (with lein repl), and them run: (simple-brepl) > > Wait a bit, it will change your REPL into browser REPL, and it will say > that the websocket is listening. After that open you page, and you are > done, just evaluate stuff :) > Let me know if this doesn't work for you and I'll see what I can do. Cheers, Colin On 5 August 2014 02:59, John Szakmeister <[email protected]> wrote: > Sorry for pestering the list about this, but despite trying to follow > several different blog posts about this, I seem unable to get a > working ClojureScript REPL that connects to the browser. Ideally, I'd > like to start from a clean project using "lein new om-start > project_name" and get the right bits together to do this. My goal is > to be able to do the Om tutorials and try things out on-the-fly. > > Given that, I do have Clojure repl working where I can start the Jetty > server. However, when I try this: > > (browser-repl) > > As suggested by the om-start README, anything I try to evaluate just > hangs there. FWIW, I see no errors in the JavaScript console. > Looking at the raw HTML, it looks like the connection back to the > server-side for the browser REPL is correct, and the (browser-repl) > command comes back with: > > (browser-repl) > WARNING: unsigned-bit-shift-right already refers to: > #'clojure.core/unsigned-bit-shift-right in namespace: cljs.core, being > replaced by: #'cljs.core/unsigned-bit-shift-right > Browser-REPL ready @ http://localhost:60442/9462/repl/start > Type `:cljs/quit` to stop the ClojureScript REPL > => nil > > Any advice folks can give would be appreciated. I'm fairly new to > IntelliJ in general, and to this point have used Vim and a > command-line REPL to do my work. It'd be nice to have IntelliJ > working here. I should add that I'm using the Cursive plugin for > IntelliJ and not La Clojure. > > Thanks! > > -John > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to [email protected] > Note that posts from new members are moderated - please be patient with > your first post. > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > --- > You received this message because you are subscribed to the Google Groups > "Clojure" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
