This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-01-04
Channels
- # architecture (13)
- # bangalore-clj (1)
- # beginners (174)
- # boot (25)
- # cider (65)
- # cljs-dev (10)
- # cljsjs (4)
- # cljsrn (3)
- # clojure (169)
- # clojure-berlin (27)
- # clojure-brasil (32)
- # clojure-greece (3)
- # clojure-russia (31)
- # clojure-sg (4)
- # clojure-spec (6)
- # clojure-uk (74)
- # clojurescript (186)
- # code-reviews (5)
- # css (12)
- # cursive (17)
- # datascript (1)
- # datomic (45)
- # dirac (33)
- # funcool (42)
- # hoplon (25)
- # jobs (6)
- # jobs-discuss (114)
- # lambdaisland (6)
- # leiningen (1)
- # luminus (24)
- # off-topic (86)
- # om (13)
- # om-next (14)
- # onyx (75)
- # perun (2)
- # protorepl (19)
- # re-frame (2)
- # reagent (17)
- # ring-swagger (2)
- # rum (1)
- # slack-help (2)
- # specter (31)
- # test-check (5)
- # timbre (1)
- # untangled (34)
- # vim (8)
how was the trick to make my buffer a clojurescript one?
I get the dreaded ...needs a ClojureScript REPL. If you don't know....
on cider 0.14.0
@richiardiandrea That means you’re trying to evaluate a Clojurescript statement in the Clojure REPL - you need to start a CLJS REPL, either with M-x cider-jack-in-clojurescript
or by e.g. (cljs.repl/repl (cljs.repl.node/repl-env))
in your Clojure REPL
Yep I have done the second, but in boot, I thought there was a way to mark it 😁
cider just knows hehe
I tried clojurescript-mode
with no luck ..Anyway thanks
cider "knows" because the repl receives stuff back from a cljs backend. when status comes back, it mentions cljs
as far as I'm aware, you evaluate things in "java" clojure code that invokes clojurescript middleware
and the easiest that i've seen is this https://github.com/adzerk-oss/boot-cljs-repl
@richiardiandrea there is also cider-create-sibling-cljs-repl
which you can configure yourself to run the command you would like, I use this to run (start-repl)
with boot after I started my dev task in my clojure-repl
if you also use projectile you can even vary this command per project with a .dir-locals.el
file per project
@dpsutton yep I do that already, still you need to call start-repl
...Even after that I cannot evaluate code in the buffer
I will try to investigate today
You need task + invoke a function
After that I get to the cljs.user
prompd
But every eval command gives me that error
Oh OK cool
you should see a session id of your clojure repl and then hopefully see a new session id for the clojurescript backend
Ok thanks for the details I will check in a bit (on the bus to work now)
No cljc
if you want to send me a link to a repo that can easily demonstrate the bug i'll look at it tonight
Ok Yes I have a repo, it is a bit hacky as I am porting figwheel to boot but it should work anyways
To be in the same situation you should grab the fighweel
branch here: https://github.com/boot-clj/boot-figreload
And use the sample project here: https://github.com/arichiardi/fig-boot-reload
If it's too much work don't worry I will be checking that during the day
One thing is that if I copy and paste the form the repl (of course) works
@dpsutton it looks ok in the project above so I might actually need to try another demo project
that's what cider remembers and when its looking for a clojure script repl it goes on that value
mmm I don't know yet, let me try the other prj, but thanks I did not know that and now my debug can be more focused 😉
just found it 🙂
@dpsutton the problem solved by itself, magically
by the way it has to do with the execution/connection order
I have to launch boot
, then connect to nrepl
, then ((eval 'adzerk.boot-cljs-repl/start-repl))
in the repl buffer, then connect the browser to localhost:PORT
no yeah definitely makes sense 😧
just that after a couple of months of not using it, I probably forgot 😄
hi there
I’m trying to debug a web app but I’m not sure how to go about connecting to the running webserver
I usually run it with a boot task, I thought I would be able to connect to it through cider-jack-in
but it spins up its own nrepl
is cider-connect
and loading the app env myself my only option ?
If your web app starts its own nREPL server, then you can cider-connect
to it and it will have the app env already set up.
oh right I thought I would have to load the env myself
thanks