This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-01-18
Channels
- # announcements (2)
- # aws-lambda (14)
- # babashka (4)
- # beginners (66)
- # clojure (113)
- # clojure-spec (9)
- # clojure-uk (7)
- # clojurescript (24)
- # data-science (12)
- # datomic (45)
- # docker (2)
- # emacs (1)
- # fulcro (48)
- # jobs-discuss (22)
- # kaocha (7)
- # keechma (3)
- # luminus (7)
- # off-topic (7)
- # re-frame (6)
- # shadow-cljs (43)
- # spacemacs (18)
- # tools-deps (2)
- # vim (1)
- # vscode (2)
- # yada (11)
is this object notation allowed in shadow? (foo.bar.baz)
cljs docs says its supported (https://cljs.github.io/api/syntax/dot), but not sure why i'm receiving use of unresolved var
specifically the require looks like this
[lib.core :refer [comp]]
and i'm trying to use it like this
(comp.view (comp.text "Hello World"))
i'm looking at adding a bit more support to clojure-lsp for shadow. The base for this is knowing the classpath for a project. I see that you can run shadow-cljs classpath
and get the classpath but it unfortunately prints out some info that is unnecessary like config, node version, etc. Is there a way to get just the classpath info without any of this extra information?
@dpsutton the "extra" info is printed to stderr. the classpath info should be the only thing on stdout
I’m coming back to clojure and CLJS after a hiatus, and I’m curious how shadow-cljs compares to figwheel-main. Last I checked, shadow-cljs was superior for integrating nodejs libraries.
@dpsutton on a slightly related note, if invoking shadow-cljs via npx or yarn, those have flags to be more quiet in the output. for npx it's --quiet
and for yarn it's --silent
.
i also used shadow-cljs classpath in a project and found that without the --quite and/or --silent flags was seeing extra output (if using yarn/npx). at least that was my recollection. i don't recall exactly what happens without them, but i found that using the flags seemed to help 🙂
for reference: https://github.com/sogaiu/alc.index-defs/blob/master/src/alc/index_defs/impl/paths.clj#L88
npx --help
says:
--quiet, -q Suppress output from npx itself. Subcommands will not
be affected. [boolean]
Awesome. Thanks for the pointer. I bet that’s truly awful to figure out in the wild :)
@thheller Ah, ok. It’s nice to be back. 🙂 What about rebel readline? I guess that doesn’t matter with cider, correct? Do you have feature list for comparison? I’m sure you hear this question all the time
I can't do comparisons since I have never used figwheel or figwheel-main. rebel-readline is not supported but that doesn't matter with cider. cider has good support for shadow-cljs nowadays (I think, I use Cursive)
it does 🙂 rebel readline is a terminal client and not necessary if you are using an integrated editor
So really, then, is there any reason I’d use figwheel-main? 😉
Not for me 🙂
Seriously, Shqadow does integrate better with any target I've tried. It is better on generating node (I'm using it currently on some devops projects and did some experiments with proton-native), node libraries (Chlorine is one of these, I also made a hubot script with it), browser (it can live-reload jQuery 😄) and so on
I have a side question, as well. I recently spoke with a CTO who says the Google Closure compiler is really not that great. That’s the first time I’d ever heard that, and he’s been working with CLJS for quite some time. Have you found that to be the case? Just curious.
I’d been singing praises of Closure over the usual (more common) JS ecosystem, but I don’t want to repeat misinformation.
Yes, I wish I had more to offer, but it was a brief conversation.
if you use it with code that is written for it (CLJS, Closure Library) it is absolutely fantastic with nothing else coming even remotely close in the JS world currently
I am trying to add the following as a dependency in my shadow-cljs.edn file and I get “bad artifact coordinates” error - obviously bad formatting:
[metosin/malli {:git/url ""
:sha "1a1038d2473c6de784252b6ad42a6cc1e764ebcc"}]
How do I do this?@slack1490 that is caused by a dependency conflict. likely because you are using deps.edn or project.clj. you should have these versions
[com.google.javascript/closure-compiler-unshaded "v20191027"]
[org.clojure/google-closure-library "0.0-20191016-6ae1f72f"]
[org.clojure/google-closure-library-third-party "0.0-20191016-6ae1f72f"]
@tbrooke git deps are only supported if you manage dependencies via deps.edn
. shadow-cljs.edn
does not currently support them directly.
Some people expressed interest in the web framework I'm working on. I wrote down some notes and started porting the shadow-cljs UI in case anyone is still interested. finally no more react 🙂 https://github.com/thheller/shadow-experiments https://github.com/thheller/shadow-cljs/blob/master/src/main/shadow/cljs/ui/main.cljs
Wow, great! How does it compare, for example, with reagent/react/vue? Does it uses some kind of "virtual DOM", does it listens to changes on atoms?
I wrote some more stuff here https://github.com/thheller/shadow-experiments/tree/master/doc
I'll write more about this if I decide to make this an actual framework at some point 😛