This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-02-01
Channels
- # aleph (1)
- # announcements (2)
- # aws (3)
- # bangalore-clj (1)
- # beginners (136)
- # boot (3)
- # calva (89)
- # cider (44)
- # cljdoc (1)
- # cljs-dev (31)
- # clojure (101)
- # clojure-europe (3)
- # clojure-italy (52)
- # clojure-nl (7)
- # clojure-spec (12)
- # clojure-uk (34)
- # clojurescript (62)
- # community-development (46)
- # cursive (25)
- # datomic (6)
- # duct (26)
- # events (6)
- # figwheel-main (4)
- # fulcro (25)
- # graphql (2)
- # jackdaw (4)
- # jukebox (3)
- # kaocha (57)
- # leiningen (31)
- # off-topic (3)
- # onyx (4)
- # other-languages (22)
- # pathom (18)
- # re-frame (9)
- # reitit (3)
- # shadow-cljs (60)
- # spacemacs (9)
- # speculative (22)
- # sql (39)
- # tools-deps (45)
- # vim (37)
I had some code that was essentially:
(def some-coll ["foo" "bar" "baz"])
(doseq [item some-coll]
(-> (async-thing)
(.then (fn [] (println item)))))
and it would just print "baz" three timescan anyone suggest a lint tool like eastwood that's suitable for ClojureScript? (my reading is that eastwood is Clojure only)
How about Joker? https://github.com/candid82/joker
Hi all, any suggestions for libraries and especially forms that do not require Javascript on the client side?
you can do simple HTML forms without JS and without any libs (if you are talking about server rendered HTML)
@thheller I was thinking the same while typing 🙂 I know there are some libs that also support server side rendering for example. I am looking for something along these lines and more specifically for forms.
You probably already know about it, but I’d use hiccup
I’m not aware of anything that generates interactive forms for you like rails’ form_helper and friends
But those kind of convention-driven forms would be relatively easy to make a library for
right, thanks @jimberlage. + for hiccup. Used in the passed https://github.com/teamwall/formidable but not sure if it is maintained
after a longer debugging session I seem to have discovered that in cljs.core.async, the go macro "eats" meta data, could that be right? Anyone else seen this?
cljs.user=> (meta ^:some-meta [])
{:some-meta true}
cljs.user=> (a/take! (a/go (meta ^:some-meta [])) (fn [v] (println v)))
nil
have you tried using with-meta instead?
@alexmiller I haven't. Ended up moving the literals outside the go macro in the tests I was working on. But this seems like a bug, guess I should report it somewhere proper
https://dev.clojure.org/jira/browse/ASYNC would be the place
yeah, when I read ‘value’ I didn’t know if this was a literal string/number/boolean or could also be something that evaluated to a string, I mean literal in that sense
what I wanted was something like (goog-define foo (look-into-an-environment-variable ...))
, but it’s all clear now, thanks 😉
It might actually be possible to do something like that with the underlying Closure support. For now the macro will balk at macroexpansiontime.
do I have to do anything special to call an async
javascript function defined in a library in my cljs namespace?
Try setting the :language-in
compiler option
@ccann no special settings required no. should work fine assuming you have the correct reference. did you check whatever you are calling is what you expected? (eg. by logging it before you call it? (js/console.log the-thing) (the-thing)
)
hmm thanks, it’s undefined
, so something else must be going wrong. I’m trying to pull in a library my coworker wrote via ["foo" :refer [baz]]
all that matters to CLJS is the classpath https://shadow-cljs.github.io/docs/UsersGuide.html#classpath-js
I corrected the path and now it’s finding the file i’m trying to import but failing to compile throwing an “errors in files” on a file i’m not trying to import that’s in the same directory as the one I am. I’ll delve into this, thanks for all the assistance