Fork me on GitHub
#cljsrn
<
2017-07-04
>
pesterhazy13:07:31

@gphilipp I've reached the point where I have to react-native bundle myself now

pesterhazy13:07:04

did you reach any conclusion?

pesterhazy14:07:30

for testing, you need to pass --reset-cache to react-native bundle, otherwise it'll use the pre-computed work

pesterhazy14:07:59

I did not know that you could run a Release Build simply like this:

react-native run-ios --configuration Release

pesterhazy15:07:30

the trouble is, I don't periodically read the entire RN docs to see if something changed 😉

pesterhazy15:07:22

--max_old_space_size=4092 seems to work for me with node 7 btw

gphilipp15:07:44

@pesterhazy I reverted to node 7.8 from 8.1.3 but I still have the issue with the memory. It worked fine under RN 0.44 though with --max_old_space_size=4096. Which version do you use ?

pesterhazy15:07:17

probably that's it

gphilipp15:07:52

Basically, it will just change your package.json

gphilipp15:07:17

I also noticed that it writes “ranged” version in your package.json. And this made me lose a couple hours yesterday after I had deleted the node_modules directory + npm install. It pulled 16.0.0-alpha.13 instead of 16.0.0-alpha.12 while I was looking away, and alpha13 is incompatible with RN 0.45.1. I had to remove the leading caret on the react dep and update the package-lock.json to make it work properly again w/ advanced compilation. I’m still investigating the failure under simple mode.

pesterhazy15:07:37

I think I'll just stay with 0.44 for now

gphilipp15:07:12

A strange thing is that when I look at memory usage in the activity monitor (i’m on mac), I don’t see the node process go over 1.5 go (which is the default IIRC). Seems like --max_old_space_size has no effect.

paulbutcher22:07:17

Does anyone have an example of using Picker? I’m clearly missing something very basic, but I’m failing to work out how to wrap PickerItem correctly. This is my current attempt:

(def ReactNative (js/require "react-native"))

(def view (reagent/adapt-react-class (.-View ReactNative)))
(def text (reagent/adapt-react-class (.-Text ReactNative)))
(def picker (reagent/adapt-react-class (.-Picker ReactNative)))
; (def item (reagent/adapt-react-class (.-PickerItem ReactNative)))
Uncommenting the commented-out line results in the dreaded “Assert failed: c”. What am I missing?

paulbutcher22:07:23

To answer my own question - it needs to be:

(def item (reagent/adapt-react-class (.-Item (.-Picker ReactNative))))