This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # 100-days-of-code (3)
- # announcements (2)
- # beginners (237)
- # bitcoin (2)
- # boot (5)
- # cider (15)
- # cljs-dev (9)
- # cljsrn (6)
- # clojure (75)
- # clojure-estonia (1)
- # clojure-italy (8)
- # clojure-losangeles (1)
- # clojure-nl (1)
- # clojure-spec (68)
- # clojure-uk (80)
- # clojurescript (89)
- # cursive (31)
- # datomic (22)
- # emacs (2)
- # events (3)
- # figwheel-main (184)
- # fulcro (28)
- # graphql (1)
- # hyperfiddle (2)
- # jobs (1)
- # jobs-discuss (64)
- # luminus (5)
- # off-topic (16)
- # om (2)
- # onyx (1)
- # pedestal (12)
- # portkey (1)
- # re-frame (13)
- # reagent (56)
- # reitit (13)
- # ring-swagger (13)
- # shadow-cljs (145)
- # slack-help (2)
- # specter (6)
i kind of wish that the shortcut to go to the repl would toggle between repl and last window
Hi. I am trying Cursive for a ClojureScript project with deps.edn. After crating and adding
clojure -Spom most of the "... cannot be resolved" messages are gone. But I still have many. This one for example:
(.-head js/document) causes ".-head cannot be resolved". And
(.log js/console "hello world") causes ".log cannot be resolved". How to deal with this?
Cursive does not have recognition for JS modules especially for global and browser APIs
It would need to require IDEA WebDevelopment plugins (not included in community edition) or implement it from scratch (probably time expensive)
When importing a leiningen project into intellij using cursive, I notice that all the project dependencies have a scope of "Compile". I would expect test dependencies to have a scope of "Test". Is there any way to fix this?
I raised a new issue for this here https://github.com/cursive-ide/cursive/issues/2055
@dazld I did consider that - the problem then is that you have to think about where you are currently to know what the command is going to do.
it’s like the quake console, toggle in, toggle out. I guess the context is usually pretty clear.
@witek Yes, JS interop is currently very noisy because it’s almost impossible to do correctly - I’m going to fix that soon.
@cfleming I'm trying to get the new EAP to start a REPL with a deps.edn based project - have you got anything written or could you point me in which direction I should be trying now? There are a bunch of new options and I'm not sure which one I should be trying to get work (Local REPL with Deps is the direction I'm leaning but getting an error "No modules containing clojure.main found")
@shaun-mahood That error normally means that you don’t have Clojure attached to any modules as a dependency.
As to the options you might want, there are two axes now - the type of REPL and how you want to run it. The type of REPL is basically a choice between nREPL (RPC style) and clojure.main (streaming style). Currently Cursive support is better for nREPL so I’d choose that unless you have a good reason not to.
For execution, I’d use Deps for Deps projects, since that will allow you to use aliases etc when running.
Ok, how would I translate
clojure -m figwheel.main into the format it's expecting? Nothing I've tried seems to work (screenshot in thread)
Not sure if this pasted correctly or not, I got a message from slack and not sure if you can see it or not
@shaun-mahood There’s an issue with the clojure.main REPL type which means that you can’t specify figwheel.main as the main class. I’m planning to fix that for the next EAP.
Oh that makes me feel better about things 🙂 I guess I'll leave the rest of this until then and just work on the leiningen docs
Ok - one thing to beware of is that all those options have changed, as you noticed. I’m hoping to get a stable build of this EAP out sometime soon, but I’m travelling so times are a little unpredictable right now.
I’m also planning to document all this myself soon as well - perhaps I could combine what you have into the Cursive docs? Or at least if you have notes about what’s worked well from you I can document from there from a Cursive POV and Bruce can use it from a Figwheel POV?
Yeah, I'll probably focus on the stable build for now and update when the new build comes out - my real project is still using lein so I'm not in any hurry.
My immediate plan is to document the "simple" way to use lein from a new project with just CLJS, the way I've got it running for me with CLJ and CLJS, and then another bit with the full build (CLJ, CLJS, Integrant, Uberjar, and SSL) for both dev and production. I'll send you a link to the figwheel specific docs as I get them done, but would be happy to adapt into a more Cursive centric form or you can just steal what you want.
Ok, that sounds good. I’ll be interested to see that as well since I don’t use CLJS myself.
Do I need to worry about the Intellij version for anything, or just the Cursive version?