This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-08-31
Channels
- # announcements (1)
- # babashka (27)
- # beginners (107)
- # calva (2)
- # cider (1)
- # clara (1)
- # clj-kondo (17)
- # clojure (74)
- # clojure-europe (18)
- # clojure-nl (4)
- # clojure-norway (3)
- # clojure-spec (11)
- # clojure-uk (3)
- # clojurescript (10)
- # conjure (12)
- # datomic (4)
- # figwheel-main (1)
- # fulcro (28)
- # graalvm (11)
- # hugsql (12)
- # joker (1)
- # klipse (5)
- # malli (2)
- # meander (1)
- # membrane (9)
- # off-topic (26)
- # pedestal (6)
- # remote-jobs (1)
- # ring-swagger (5)
- # shadow-cljs (4)
- # test-check (14)
- # vrac (8)
- # xtdb (8)
When running conjure with a shadow-cljs project, I'm connecting to the right nREPL session successfully, selecting the correct shadow cljs build successfully, however when I try to run any code or evaluate a buffer I'm getting a lot of errors thrown along the lines of No such namespace: js
. It's also complaining about my ns
form (`Syntax error macroexpanding clojure.core/ns`) which is valid and can't seem to find cljs namespaces No such var: cljs.reader/read-string
.
It seems to me like it's just not running JS code, but I can't figure out why after connecting to a shadow cljs session it wouldn't run cljs code
I run :ConjureConnect
and :ConjureShadowSelect frontend
and get the following output:
; --------------------------------------------------------------------------------
; localhost:3434 (disconnected)
; --------------------------------------------------------------------------------
; localhost:3434 (connected)
; --------------------------------------------------------------------------------
; shadow-cljs (select): frontend
; (out) To quit, type: :cljs/quit
[:selected :frontend]
I've loaded the browser page (connecting the browser repl) and running commands from a npx shadow-cljs cljs-repl frontend
command is successful. Anyone have any tips on investigating why conjure is not running in a cljs environment?
@bendy I just tried out shadow myself with the latest version and it's working fine for me :thinking_face: it kind of sounds like you're evaluating ClojureScript into a Clojure nREPL... maybe?
I started up a shadow-cljs server, connected (automatically) over nREPL, selected my "app", opened my browser. Then I could evaluate fine.
So I guess either a version difference in nREPL / shadow / cljs etc has caused an issue or it's something in your setup?
For reference, I use npx shadow-cljs watch app
with this shadow-cljs.edn
{:source-paths
["dev/clojure/src"]
:dependencies
[[cider/cider-nrepl "0.24.0"]]
:dev-http {8080 "dev/clojure/public"}
:builds
{:app {:target :browser
:output-dir "dev/clojure/public/js"
:asset-path "/js"
:modules {:main {:entries [dev.sandbox]}}}}}
Very strange. It does seem like I'm evaluating into a clj repl - even trying to evaluate (js/console.log "hello world")
fails for me saying js is not defined