My first React Native app!

Finally got a React Native app up in Google Play!

It’s a trivial little app, just a game for converting imperial and metric, but it’s a start!

2 Likes

Oh cool…this is on my To Do Soon list, too!
I don’t have an android phone yet to test this - would it run in the emulator you used while developing it?

I’m certainly not expert and I’m still stumbling through the process…

For the emulator, I installed Android Studio. This was tricky because the tutorials were based on an earlier version of AS with a different layout, and some of the CLI stuff deprecated. Once I got the correct packages installed (and that alone took hours and hours – and hours) then I had to start an android project just to get to where I could launch an emulator. I wish I could describe how I did it – I feel like I’m reinventing it each time. This method works well with create-react-native-app. Starting up the react native with the command react-native run-android automatically connected it with the running emulator.

But I found out that using Expo was a better workflow for putting onto Google Play. So I installed Expo and used that to created the basic app. I tried porting my existing RN over to Expo, but I couldn’t do it – maybe if I knew webpack better. So I created an app with Expo and moved the source files into that. That worked. With Expo, you can use the same Android emulator or you can install their app on your mobile device and use the device as the output – either over wifi or wire. Expo also has a nice feature where you can link over the internet – a nice feature if you need to demo something to a client on the other side of the planet.

With that, it was fairly easy to use Expo CLI commands to create and Android APK file that could be uploaded to Google Play.

I wish I could give a better explanation. Each of those packages has different pathways so I’m sure there are different ways (perhaps better) to do the same thing. Though, I do get the impression that Expo is the way to go to easily work with Google Play.

1 Like