Fork me on GitHub

@ericihli We just have three cljs builds that accomplish the same thing more or less. We have env/dev/env/config.cljs , env/prod/env/config.cljs etc. and then we just change the src config in the cljs build option to include the relevant dir.


No external libs needed.

Wes Hall11:01:50

Hey folks, with sincere apologies, as this is probably a question that gets asked hundreds of times, but I have been playing with some app development stuff and currently doing that thing of alternating between ideas of using the native languages, doing some react native in JS, or going for the full abstract and trying to put things together with RN and CLJS. Clojure is my language of choice these days, but I also worry about too many levels of abstraction and the state of the tooling. Are there any particularly shining examples of good RN+CLJS projects that anybody can link me to, so I can have a bit of a browse as to how all this stuff looks when crafted by somebody who knows what they are doing? 🙂


In general I’d say that it’s an exceptionally productive and powerful setup for developing mobile apps. The tooling can at times be quite difficult to get right though.

Wes Hall11:01:53

Thank you @vikeri. Will have a look through that project. Looks like lots going on in there. Judging by the channel title, I assume re-natal is still the goto for most people doing this stuff? I have been hearing some good things about expo, but this whole world is pretty new to me. Done a lot of server side and web stuff, but haven't really taken the leap into native mobile in a serious way.


Actually I think shadow-cljs is the preferred setup nowadays. And if you don’t need specific native features I’d definitely go with expo.

☝️ 12
Wes Hall11:01:55

Great info. Thank you.


@wesley.hall if you haven’t come across it, you might find my talk useful, there’s a link to a demo app in it, but the demo app is a bit experimental 🙂

👍 4

our prod app isn’t open source I’m afraid though

Michaël Salihi13:01:53

@wesley.hall You can check this repo, if you want try "Shadow-CLJS + Expo + Re-frame" instead Re-natal

👍 12

I did something very similar but with a few more dependencies. 😉

👍 4
Wes Hall14:01:30

Thanks folks. Just going to be in a bit of a meeting fest for the rest of the day but will look at both tonight :)


Another repo you might want to consider, is this one (not a lot in the README, but plenty of detailed explanations in the comments on how to structure the app and how to use react-navigation) /cc @wesley.hall

👍 4

Hi everyone 🙂 I want to share a library that I just published that helps you write modern React components with CLJS (yet another!). I started on a CLJS/RN project recently and felt that the various frameworks libraries out there didn’t try hard enough to get out of my way - surely it’s a matter of preference, but I really just wanted to define components using defn instead of some DSL or helper. I left state management out of scope, and I think ended up with a nice API that achieves the goal with strong extensibility. Broadcasting here because I’m happy with it and hope someone out there finds it useful 😁 Feedback welcome! Link below


Interesting! I’m personally very happy with reagent and re-frame. Did you try those and if you did what did you find the issues to be?


Thanks. I started the RN project with reagent/re-frame from the stencil, but my thinking was: 1. Saw hooks/async render/scheduler improvements in recent/upcoming React core dev 2. ^ Gives leverage to a small library focused on mapping to native components 3. Skeptical of the leverage of reagent’s reactivity/rendering solutions in light of ^^. Wondered if reagent’s solutions wouldn’t track these improvements due to all the custom mechanics. 4. I vaguely recall being petty about the way I had to use r/adapt-class and interop with native components, whether using native components in reagent components or vice-versa with react-navigation. I forget if this pettiness was justified, but wanted to be closer to native components to minimize problems. 5. Was focused on ergonomics of my current problems, probably neglecting most of the reasons that the other frameworks are so built out. So I started writing the library. Of course I then had to implement a state-management library, which made it less of a win since I recall re-frame looking really nice but coupled with reagent… In any case, that’s more or less the origin story :)

👍 4

Interesting. re-frame is pretty killer. Would be very interesting if you could switch out reagent for your implementation.