cljsrn

https://github.com/drapanjanas/re-natal | https://github.com/drapanjanas/re-natal/wiki/FAQ | https://github.com/condense/mercury-app/wiki | https://github.com/seantempesta/expo-cljs-template/ https://www.npmjs.com/package/create-expo-cljs-app
pez 2021-06-10T12:01:36.123Z

Anyone know of some nice resources on performance profiling a cljsrn app? I see huge slowdowns on Android when upgrading an app from RN 0.61 to 0.64, and I’m out of ideas about how to pinpoint where it happens.

raspasov 2021-06-16T12:40:42.135800Z

No personal experience with React Navigation but it would be suspect also for me. I think every major React Navigation version was quite a big change.

dima 2021-06-10T12:36:09.123400Z

There is a systrace for Android which can then be viewed in <chrome://tracing/>Β https://reactnative.dev/docs/profiling#profiling-android-ui-performance-with-systrace

pez 2021-06-10T13:22:37.124Z

Thanks!

raspasov 2021-06-10T14:35:56.127600Z

Are you sure that upgrading RN was the only change that happened? It could very well be, or it could be something else. Last time this happened to me (on iOS), the culprit was DataScript and my lack of knowledge of how to use it properly. It took me 2-3 days to figure out where the performance problem was (mainly via guessing).

kennytilton 2021-06-10T14:36:30.128400Z

Trying to evaluate re-natal, I ran into a problem and thought I would check my dependencies more closely. The RN CLI dependency says "react-native-cli >=0.1.7 (install with npm install -g react-native-cli)". Unfortunately, RN doc now warns "If you previously installed a global react-native-cli package, please remove it as it may cause unexpected issues. Instead we use npx on each command. Which way do we go? Will re-natal be OK with the npx approach and an uninstall of reactive-native-cli?

raspasov 2021-06-13T14:19:09.132300Z

More build approaches? figwheel-main and shadow-cljs are not good enough? πŸ™‚ Plain setup via deps.edn also works, but comes with less bells and whistles.

kennytilton 2021-06-15T12:39:54.132700Z

How did you forget Boot?! πŸ™‚

πŸ‘Œ 1
raspasov 2021-06-10T14:37:26.128500Z

Last I checked re-natal does not seem to be maintained anymore. shadow-cljs, figwheel-main, and krell are all viable I think at this point for React Native + CLJS.

πŸ‘† 1
raspasov 2021-06-10T14:38:16.128900Z

(I personally use figwheel-main)

pez 2021-06-10T14:39:28.129100Z

The change involves an upgrade of React Navigation as well. Otherwise just the necessary bumps and changes for the upgrades.

pez 2021-06-10T14:40:25.129300Z

In dev the slowdown is something like 100X, for release builds maybe 10X (very unscientific measures, just the gut feeling).

pez 2021-06-10T14:41:59.129600Z

Could still be a bad usage of re-frame or something else, of course, but that gets exposed only on Android and together with something between RN 61 and 64, or between react navigation 3 and 5.

kennytilton 2021-06-10T15:07:53.129800Z

Thx. I saw David giving a big shout-out to re-natal on the Krell page and thought I would give it a whirl. Up next: figwheel-main.

raspasov 2021-06-10T15:33:20.130Z

Yes… I believe it was more of a historical reference but I see how it can be confusing πŸ™‚

πŸ‘ 1
raspasov 2021-06-10T15:33:42.130200Z

https://figwheel.org/docs/react-native.html Last I tried this tutorial should be able to get you going to a dev setup.

kennytilton 2021-06-10T22:10:22.130900Z

Yes, that ^^ worked great. And rn-rf-shadow also came up OK, which is clutch for a re-frame effort we have in mind. Thx!

πŸ‘ 1
kennytilton 2021-06-10T22:13:51.131100Z

I just wish Clojure/CLJS had more build approaches. I know of six, but seven is the lucky number. πŸ™‚ Effectively, the language was mature and stable almost at birth but in fifteen years we have not figured out how to run it. :face_palm: