This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-05-18
Channels
- # ai (1)
- # beginners (71)
- # boot (15)
- # cider (26)
- # clara (4)
- # cljs-dev (81)
- # cljsrn (26)
- # clojure (393)
- # clojure-berlin (2)
- # clojure-dev (5)
- # clojure-dusseldorf (1)
- # clojure-greece (5)
- # clojure-italy (6)
- # clojure-russia (97)
- # clojure-serbia (11)
- # clojure-sg (2)
- # clojure-spec (14)
- # clojure-uk (66)
- # clojurescript (58)
- # core-async (19)
- # cursive (18)
- # data-science (2)
- # datomic (75)
- # emacs (20)
- # events (5)
- # figwheel (1)
- # graphql (2)
- # hoplon (29)
- # jobs-discuss (3)
- # juxt (6)
- # lein-figwheel (1)
- # london-clojurians (2)
- # lumo (29)
- # mount (9)
- # off-topic (4)
- # om (16)
- # onyx (25)
- # other-languages (2)
- # pedestal (38)
- # protorepl (2)
- # re-frame (20)
- # reagent (9)
- # ring-swagger (6)
- # sql (10)
- # unrepl (3)
- # untangled (19)
- # utah-clojurians (1)
- # videos (2)
- # vim (20)
Hey all, more a thought than a question. I don't really know exactly how re-natal wraps RN, but recently (like a few minutes ago), I had an issue with MultiDex for a rather small project (only used 3 external packages: StripeReact
, ReactNativeOneSignal
and ReactNativeMapboxGL
). I wonder if the multidex could be enabled by default. It's a bit a mess to do it manually (especially for novices - fiddling with Java classes is not really something called 'fun'). - https://developer.android.com/studio/build/multidex.html
I got the idea to do simple optimizations of my app to have a single file for production. But it seems to be too much for the RN packager… It times out after 300 seconds. Any tips on how to get a good production build?
@vikeri you could try https://github.com/callstack-io/haul it has a bundle
command
haven't tried it yet but haul
seems very promising as it doesn't process the CLJS code so heavily (thus no slowdown)
@vikeri what I do is to disable whole-program optimizatitions
basically I use the bundle step with --dev
the downside is that it sets __DEV__
to true
in the resulting js bundle
but you can manually go in and replace that string
hacky as hell but it works
you can also try to give the node process more RAM (it's capped to 1GB (?) by default)
people have done that with varying degrees of success 🙂
is there a resource of sorts where current problems with react-native
+ CLJS are collected?
@pesterhazy Ok interesting. It’s actually not the memory that is the issue for the packager, it just times out trying to transform the file. I wonder what optimizations that are most valuable, google closure or rn packager…
@vikeri it doesn't matter that much anyway... bundle size is not very important for apps
you could try disabling transforms in .babelrc
that's also been known to help... sometimes
@pesterhazy I just found this out from the react-native issues: https://github.com/pesterhazy/boot-react-native/blob/develop/example/rn-goog-require.patch Any reason why you didnt continue with it?
It's included in boot-react-native and works alright there. What do you mean by continuing?