While React-Native provides reusability, efficiency, and flexibility, it’s not without its limitations. Critics cite that React Native adds unneeded complexity as well as the management of an extra code base. To learn more about the advantages/disadvantages, check out the recent post from Daniel Bostwick which discussed questions to consider when deciding between native and React Native.
In today’s post, I’ll focus on a useful feature of React Native, Over-the-Air (OTA) updates, which allows for quick and painless delivery of bug fixes and in-app improvements.
OTA allows React Native developers to publish updates directly to their users' devices without submitting a new version to iTunes connect (iOS) or the Google Play Store (Android). This functionality provides a dynamic deployment experience similar to web application development. To understand how and when OTA can be used, let’s take a high-level look at the React Native architecture.
React Native Architecture
Native Mobile Deployment
Deploying native mobile apps is a lengthy process; developers need to compile and distribute a platform-specific binary to their respective stores. .ipa (iOS) binaries are uploaded to iTunes connect, while .apk (Android) binaries are uploaded to the Google Play store, each with its own set of upload steps. Once a binary is submitted, a rigorous review process begins, which historically has been slow and unpredictable. While this review process has become expeditious over time, it can still be highly variable. For example, this past spring, a cosmetic update for a client was rejected from the App Store, which delayed its release by several days, due to missing information about a feature that previously had been approved. Surely, such headaches can be avoided by allowing adequate time to process updates, but sometimes mistakes happen that require a quick fix and this is when OTA becomes very useful.
When to use OTA
OTA allows developers to quickly resolve bugs and deploy quick updates. Below are a couple examples of OTA reducing pain on Cantina projects:
While building the 2017 Newport Folk Festival app, we failed to enforce timezones for each event. On the east coast, events appeared correct, but elsewhere, event times were incorrect, causing concern for artists’ managers. Utilizing OTA updates, we were able to quickly publish a patch.
During the inaugural Your Call Football season, game start times were rescheduled at the last minute, requiring a quick copy change in the app. With OTA updates, we were able to modify the game schedule right away.
While OTA is great for bypassing the Apple or Google approval process for minor updates such as these, a brief note of caution: If making major application updates, these changes should be published through each platform’s store, to avoid trouble with Apple/Google.
Microsoft Code Push
Microsoft’s CodePush is a great tool for managing OTA updates; it’s easy to configure, integrate, and best of all, it’s free. CodePush offers a few notable features. First, it maintains a copy of the previous update, so if a new change causes an app crash, CodePush will revert to the previous crash-free version. This is helpful in preventing any downtime for users. Second, CodePush offers multiple deployment strategies, allowing developers to control the frequency and presentation of updates to end users. For more information, CodePush offers great documentation.
In summary, OTA allows React Native developers to streamline mobile app deployment and deliver updates to their users in minutes rather than days without the headache of Apple/Google store approval. While OTA is not a replacement for major app store updates, OTA is an efficient tool to have in your back pocket when app store deployment hits an unforeseen roadblock or you simply need a quick fix. Stay tuned for future posts, discussing the benefits of using React Native for mobile development.