My Thoughts on Jetpack Compose

My Thoughts on Jetpack Compose

So yesterday I decided to jump in and make a Jetpack Compose (JC) app. I've been on this "sunset Flutter" movement and I'm going to prove my point in a few moments. To get started I'd like to say that recently I've also been studying swift ui (SUI) and was recommended a book on mindset shift for declarative ui. You can check the book for swift here, but if you want the Android version go here. I'm mentioning this because swift ui and jetpack compose are probably the last step to removing the barrier of entry into native mobile development.


There are so many emotions. When I started I was thinking this is very SUI-y, but then I was reading "Thinking in Compose" and then it felt like React Native (RN). There is a container-ish mindset I have when building RN apps bc it's also very web-y. So I was trying to mix the two. The more I tried to figure things out the more things started to feel like flutter. I check out a Flutter app of mine and this is flutter.

You might be thinking "ok but it's not" and to that I say "ok but it is". Every line I'm writing, how the alignment and things are written...this syntax is dart/flutter. The crazy part is I like it! I think that JC is the results of Google really studying the hybrid market and then seeing SUI and thinking "ok it's time to merge these'.

My biggest cons right now are lacking documentation (very common with google beta things) and the "live build" option. Documentation wise I don't think google has done enough. I had to do a mix of code labs, github, and fingers crossed google searches to get a simple counter app to work. That's crazy. Why couldn't I see the widget details like I do for other android things? Instead I'm clicking these common components to see the underlying code to find all my options. At one point I had ~5 components open.

When it comes to the build view I'd prefer something like iOS where I can also test functionality within that little screen. I know there is a emulator inside AS now, but why not use that on the JC side view since you have to run a full gradle build anyway to update the view? Maybe this is something the team is thinking about? I don't know but I will be keeping an eye out for it.

My 'last" emotion I want to talk about is confusion. Confusion on why I always need the artic fox or a canary ide build for these new things Google is so proud of and starting to push. Once your serious and have x amount of users why can't you add it to the main ide? I remember I had to do this round about why of setting up flutter before it got added to the ide. Now I realize I should have just rocked with VSCode until it was integrated, but what is wrong with a feature flag system?

I'll be looking forward to deleting artic fox and building everything with the main ide given how intensive it use to use Android Studios. When the merge does happen I hope my other recommendations are considered (if a google person reads this).

Final Thoughts

After completing this simple app I started yet another app. Looking at code examples on github something clicked. THIS IS FLUTTER. lol Flutter in itself is not a platform I recommend (for mobile). It's bloated and requires too many imports if you watching security. At this point I'm feeling like I'm using flutter structure with kotlin skills, and that's ok. I think that's the point. So much of this also feels like I can copy and paste swift ui code, make a couple of tweaks, and have 2 apps in no time. I felt this same way about swift and kotlin a few years ago. Flutter wasn't exciting to me as a real next step move in mobile after building a real application, but Jetpack Compose has my vote of confidence.  I don't work for google but I recommend they merge the teams, sunset Flutter as a mobile platform, and then beef up Jetpack Compose documentation.

Next Steps

My next step is to finish my small app, publish it, and then write another post. I want to see how my publishing process changes as well since there are a lot less managed files. After that I plan on seeing if I can straight up copy and paste code from jetpack compose to swift ui. If that is possible then I think hybrid development has met it's match and the field has officially gotten really interesting.

If you have any thoughts and want to share feel free to reach out to me. (if I have any luck there will be comments below)