This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-07-17
Channels
- # bangalore-clj (2)
- # beginners (51)
- # boot (20)
- # cider (14)
- # clara (1)
- # cljs-dev (14)
- # cljsrn (50)
- # clojure (140)
- # clojure-dev (5)
- # clojure-france (1)
- # clojure-gamedev (3)
- # clojure-italy (4)
- # clojure-poland (3)
- # clojure-russia (8)
- # clojure-sg (1)
- # clojure-spec (64)
- # clojure-uk (51)
- # clojurescript (54)
- # core-typed (1)
- # data-science (2)
- # datomic (61)
- # docker (1)
- # emacs (6)
- # events (1)
- # graphql (1)
- # hoplon (14)
- # leiningen (8)
- # luminus (3)
- # mount (6)
- # off-topic (18)
- # om (17)
- # parinfer (34)
- # pedestal (47)
- # play-clj (1)
- # protorepl (1)
- # re-frame (56)
- # reagent (11)
- # ring-swagger (5)
- # rum (6)
- # sql (1)
- # uncomplicate (2)
- # vim (3)
- # yada (31)
Can someone tell me what the :>
notation means when using components?
(i.e)
(fn []
[:> someComponent {}])
Hi, I saw there's a project https://github.com/ds300/react-native-typescript-transformer it provides a transform module to RN packager, can cljs do this?
@shoxter IIRC, it's a short form for adapt-react-class
that can be directly used in hiccup.
I’m having a problem where my app is working with :simple
compilation, but failing in :advanced
. If I enable :source-map
support, how can I get Chrome Devtools to use the source map?
@seantempesta unfortunately the last version of the rn packager broke the patch that re-natal used to enable source-maps in chrome. I am having the same problem. Still searching way to make it work
I also enabled them and can see them on my project but somehow devtools simply ignores them on the source
tab 😕
Right now I am looking into trying to replicate the re-natal patch for the rn packager into the latest version.
@seantempesta you can use pseudo-names instead to trace the mangled name
you could also search for all instances of (.-
and (.
in your code 🙂 or look at the mangled bundle
@seantempesta have you tried using the master
branch of re-natal? I just saw that @drapanjanas recently fixed that: https://github.com/drapanjanas/re-natal/blame/master/re-natal.coffee#L372
I’m trying to use DeckSwiper
from NativeBase. http://rawgit.com/GeekyAnts/native-base-docs/v2.0/_book/Components.html#deckswiper-headref
I got this error at renderItem
attribute of the DeckSwiper component. “Objects are not valid as a React Child (found: object with keys {name, id, class} ….“. Any idea how to translate this to reagent/hiccup syntax?
<DeckSwiper renderItem={item => <Card></Card>} />
I have an extremely basic question that I can't seem to dredge up an answer for from the internet: how do I add binaryage/devtools to a cljsrn app? I added it to :dependencies
and [devtools.preload]
to :preloads
, is there something else to it? it should just show up right?
@daiyi Are you calling (devtools/install! [:formatters :hints])
somewhere in your code?
I am not, because I'm following these instructions in the documentation: "ClojureScript supports :preloads compiler option which allows you to require namespaces prior your :main namespace. This means that you can use this feature to add cljs-devtools support to your project without modification of your code. You simply add devtools.preload into the :preloads list." https://github.com/binaryage/cljs-devtools/blob/master/docs/installation.md#install-it-via-preloads
okay I put it at the top of my main.cljs
and now it says "Installing CLJS DevTools 0.9.4 and enabling features :formatters :hints :async" in the console! but nothing is formatted D:
may be you figured it out already, but fwiw, the second point of https://github.com/binaryage/cljs-devtools/blob/master/docs/faq.md#user-content-why-some-custom-formatters-were-not-rendered helped here.
also, :preloads and :closure-defines don't seem to work in re-natal atm: https://github.com/drapanjanas/re-natal/issues/46 - hacking figwheel-bridge.js as described seems to work fwiw.
mfikes: it seems that your request was granted faster than expected 😄 https://clojurians.slack.com/archives/C0E1SN0NM/p1500059378739469
@mfikes do you know how could this inpact re-natal? I mean currently we have this .re-natal
file such that we can require the modules beforehand such that figwheel recognizes them (at least that is my understanding). Would that change with this release?
What is the context of the question? Are you asking whether using :target :nodejs
affects re-natal
?
no. I am asking whether the cljs compiler recognizing node requires affects figwheel? which in turn would then affect re-natal (afaik)
specifically I am talking about this: https://github.com/drapanjanas/re-natal#using-external-react-native-components
We, I’m using re-natal
with Figwheel
, and have converted my project to use :target :nodejs
, as well as all of the code in it to use stuff in ns
forms, and nothing has broken.
So I guess you still need to call use-component
to get figwheel to play nicely with react-native?
@mfikes what's the difference between these 2 when it comes to requiring node modules? (I saw the former few days ago in one of the cljs compiler announcements, if I am not confusing it with something else):
(:require ["foo-bar" :as fb])
;; and
(:require [foo-bar :as fb])
I think for that example there ends up being no difference, but it matters when the thing being required really needs to be a string.
FWIW I thought this was confusing a bit in the post (in Antonio’s)
I suspect that internally, a string may be afforded different behavior inside the compiler, but I’m not sure
My guess is that it turns into a path, where symbols would be invalid. Like "foo/@bar"
, etc.
not too enlightening
Thomas, like I said we should have updated the ticket. I also suggested string based require and it just didn't have anything to do with all this other stuff that you are suggesting in this issue. Supporting Node.js style paths as requires is just never, ever going to happen. Whatever you had in mind is not what I had in mind
@misha react-dom/server
is an invalid symbol, which is why we added strings to the require
spec
foo-bar
is valid and should be used
@anmonteiro thank you. Is it valid to say: strings are only for slashes? Or are there any other corner cases?
@misha I don’t know. NPM has half a million packages or something
who knows what crazy names people give their packages? 🙂