specter

Latest version: 1.1.3
wilkerlucio 2018-11-09T13:35:17.040900Z

@nathanmarz we can check by the output that its using the clj version, so its a fact that the JS out is using the CLJ version, macros sometimes are confusing on CLJS side, IME what works best is separate clj and cljs macros in different namespaces (both been .clj) and conditionally import then, this usually works with the least surprises

wilkerlucio 2018-11-09T13:35:48.041200Z

example code in pathom doing this: https://github.com/wilkerlucio/pathom/blob/master/src/com/wsscode/pathom/connect.cljc#L9-L12

2018-11-09T18:03:03.042Z

👋 Hi everyone, can anyone tell me how to :require individual navigators? (e.g., MAP-KEYS)

2018-11-09T18:03:14.042200Z

in clojurescript

2018-11-09T18:22:18.043300Z

It seems to work using

(:require [com.rpl.specter   :refer [MAP-VALS MAP-KEYS]  :refer-macros [select transform traverse setval]])
but Intellij no likey, no big deal as long as I'm not "doing it wrong" ™️

jsa-aerial 2018-11-09T18:27:19.045300Z

Are you doing this in Clojure or ClojureScript? If the former the :refer-macros does not make sense. If the latter (cljs), then this looks correct. In Clojure you can just refer the macros in the :refer vector.

2018-11-09T18:27:32.045600Z

cljs, yes

jsa-aerial 2018-11-09T18:28:05.046200Z

Not sure how intellij (Cursive??) works with CLJS...

2018-11-09T18:28:13.046400Z

Cursive, yes

jsa-aerial 2018-11-09T18:28:36.047Z

I don't use Cursive, but in emacs I do that sort of thing all the time with no problems

2018-11-09T18:28:44.047200Z

sweet

2018-11-09T18:28:47.047400Z

in cljs?

jsa-aerial 2018-11-09T18:28:52.047600Z

Yes, in cljs

2018-11-09T18:28:56.047800Z

thank you sir

jsa-aerial 2018-11-09T18:29:21.048300Z

So, it probably is some limitation / issue with Cursive and CLJS

2018-11-09T18:29:40.048700Z

yep, no worries, as long as I'm not doing it incorrectly 😉