Open Guliy opened 6 years ago
Hi @Guliy, you're going to have to do a bunch of extra setup to get cider-jack-in-clojurescript
to work properly. You can have a look at the Chestnut template, in particular env/dev/user.clj
and .dir-locals.el
. Without that CIDER will use its defaults to get to a ClojureScript REPL, which I believe is a Rhino or Nashorn based REPL, so it is not using Figwheel.
There's an extensive Lambda Island episode about configuring Emacs for use with Figwheel: 15. Using Figwheel With Emacs, part 2: CIDER
The examples in this repo are really just minimal examples, and they've only been tested as documented in the README.
What you can do is do a regular cider-jack-in
, and then use the Figwheel sidecar API to switch to a clojurescript repl, see Using the Figwheel REPL within NRepl
I have setup my emacs for work with Figwheel. It's works. I localized the problem, which is to use :npm-deps in cljsbuild compiler config. If removed this section - all works well. But in this case i need install npmdeps manually. Yes, you right, problem in defaults settings cider-jack-in-clojurescript, but i can't decide its with new version clojurescript. At this moment my decision - used lein-npm plugin
Hi! thanks for the work you've done, this is very useful!
But, I met with the incomprehensible behavior of the replays, when I try to set an example in an emacs. After cider-jack-in-clojurecript - cjs repl work very sow. Just eval (prn "test") - take up to 10 s I tried run in terminal lein figwheel and then in emacs cider-connect, but i get something like this in emacs repl buffer:
And then after run (require '[figwheel-sidecar.repl-api :as ra]) in emacs repl buffer i get in terminal something like this:
And then repl starts work slow in terminal too. Any idea what I'm doing wrong?
My project.clj: `(def shared-compiler-settings '{:main npmdemo.core :npm-deps {:express "4.16.2" :ws "3.2.0"} :install-deps true :infer-externs true :target :nodejs})
(defproject npmdemo "0.1.0-SNAPSHOT" :description "" :url "http://github.com/lambdaisland/npmdemo" :license {:name "Mozilla Public License 2.0" :url "https://www.mozilla.org/en-US/MPL/2.0/"} :dependencies [[org.clojure/clojure "1.9.0-beta3"] [org.clojure/clojurescript "1.9.946" :scope "provided"]]
:plugins [[lein-cljsbuild "1.1.7"]]
:jvm-opts ["--add-modules" "java.xml.bind"]
:min-lein-version "2.6.1"
:clean-targets ^{:protect false} [:target-path :compile-path "dev-out" "out"]
:cljsbuild {:builds [{:id "dev" :source-paths ["src"]
:figwheel {:server-logfile "log/figwheel.log" :nrepl-port 7000 :server-port 3450}
:profiles {:dev {:dependencies [[figwheel "0.5.15-SNAPSHOT"] [figwheel-sidecar "0.5.15-SNAPSHOT"] [cider/cider-nrepl "0.16.0-SNAPSHOT"] [com.cemerick/piggieback "0.2.2"]]
` Cider version 0.16.0snapshot
Emacs 25.3.1