arrow icon
REGISTER

Building Component Libraries for React Native Apps

2019-05-28
Download your copy of the
Ultimate Guide to React Native Optimization

blog content

Need help with Performance Optimization? 
hire us
Need help with Super app development
hire us
Need help with React Native?
hire us
Need help with migration to React Native?
hire us
Our React Native EU Conference is back
register nowlearn more

This is a summary of the talk I gave at App.js on 4th April 2019. You can watch the full talk in the video link below. You can find the slides here.

I am a core contributor to React Navigation and React Native Paper, as well as the author of libraries such as React Native Tab View. I hope my experience with working on them can be helpful to you.

When I say component library, I refer to a collection of reusable components. By using a component library, you reduce extra boilerplate in your app and can get productive faster. It’s very common to follow a style guide when designing a component library, resulting in a consistent design across your apps.

Building a library can be very different from building an app. In apps, most of the time we can hardcode certain things. Libraries tend to be more generic because we don’t know all of the ways the user is going to use the library.

Cross-platform

A promise of React Native is cross-platform development. Lots of people come to React Native, so they can write a single codebase and use it for multiple platforms. But cross-platform development is not easy. Apart from the design, there are many other fundamental differences between platforms that we need to address when writing cross-platform code.

Overflow

One of the biggest examples is overflow behavior. On Android, <rte-code>overflow: hidden<rte-code> is the default, on iOS, <rte-code>overflow: visible<rte-code> is the default. This can be very tricky, so the best way to handle this is to always assume that overflow is hidden by default when working on cross-platform components.

In recent versions of React Native, you can actually set overflow to visible on Android, but gestures such as touches won’t work in the overflow region.

Text background

Another difference is that, on iOS, text elements have an opaque background color by default for improved performance. It works fine on solid backgrounds, but not when you have a background image, for example. You can explicitly set it to transparent to avoid this behavior when needed.

text background in mobile app

Touchables

gif presenting touchable button in react native
gif presenting another variation of touchable button n react native

The other difference is the Touchable components. On iOS, touchables such as buttons tend to change the opacity when pressed, while on Android 5 onwards, there’s a ripple effect. Unfortunately React Native doesn’t provide a single touchable which has appropriate behavior based on the platform, so you’ll need to build your own component which renders the appropriate touchable.

To avoid repeating this every time, you can use the react-native-platform-touchable library made by Brent Vatne. It renders a ripple effect on supported Android versions and an opacity effect on iOS and unsupported platforms.

In react-native-paper, we have a similar component which renders a ripple effect or a highlight effect based on the platform. We also have a separate touchable implementation for the web which renders a ripple effect similar to Android.

Elevation and Shadows

Next difference is that there’s no support for shadows on Android. Instead, there’s an elevation style which maps to the native elevation property. Elevation refers to the position of the element in the z-axis. The higher the element is, the bigger its shadow.

Basically, it renders a predefined shadow based on material design guidelines depending on the value you provide. There’s not much to customize. Elevation also affects the position in z-axis similar to z-index, so you have to be careful when using it.

To handle this inconsistency, I like to have a single shadow function which calculates shadow properties for iOS and web, based on the elevation value. Here’s a very rough implementation in the slide. In react-native-paper, we have a more robust implementation which produces a more accurate result and handles animated values as well.

Notch and StatusBar

Handling the notch is always annoying when writing a library. In React Native, the notch is handled by <rte-code>SafeAreaView<rte-code>. Older iPhones and many Android phones don’t have a notch, so we have to handle the status bar height.

A common example is that we have a header in the app and we want it to appear below the translucent status bar. But we also want to add top padding so that it doesn’t overlap any content such as the header title.

screenshot presenting notch and status bar in react native

Every app can have a different StatusBar/Notch height based on the platform, iOS version, whether translucent status bar is enabled on Android or not, etc. There’s no single cross-platform API to get the status bar height. There is a <rte-code>SafeAreaView<rte-code> API, but it only supports iOS 11+, and can be troublesome when you’re animating views containing the safe area.

Currently, we have some custom logic in react-native-paper to try and guess the status bar height. We take into account whether the user is using Expo, Android or iOS, and apply the default heights for those environments. On iOS 11 and above, we use the available SafeAreaView instead. We also have a prop to let the user manually override this value. This approach is not perfect. The value we guessed might be often wrong, and we are using a constant value even if the status bar height can change over time. But this is the best we can do right now.

Fortunately, there’s this pull request opened by Janic which adds an API to get the height of the Navigation bar at the bottom and the StatusBar on both Android and iOS. So look forward to a much easier way of handling Notches and StatusBar in the future.

screenshot presenting new layoutcontext api in react native

Platform-specific code

When it’s not possible to have a single implementation for all platforms, there are different approaches we can use to provide platform-specific implementations. One of them is by android, ios or native extensions in the filename.

Sometimes it’s not possible to support all platforms. But when we’re using the file extension approach, we should always provide a fallback implementation, even if it renders nothing. Why? For example, say 9 out of 10 components in the library work on all platforms, but one component has platform specific implementation. If we don’t provide a fallback for this component, it becomes impossible to use the whole library for that unsupported platform.

Metro looks for specific extensions like ios.js or android.js, then more generic native.js, and then just .js. We can take advantage of this and use the most generic extension as the fallback, and have platform specific implementation in the files with more specific extensions.

The other way is to use the <rte-code>Platform.select<rte-code> API. When using <rte-code>Platform.select<rte-code>, we can use the default key to provide a fallback.

There are a lot more other platforms besides Android, iOS, and Web:

  • Windows
  • TV OS
  • Mac OS
  • Tizen
  • Many more…

The main 3 platforms I try to support are iOS and Android and Web. With awesome tools like Expo starting to have web support by default, it’s much easier to support web in your app.

The key to supporting multiple platforms is to prefer JavaScript modules when possible as opposed to native code. Sometimes JavaScript code doesn’t provide the same experience as native, but when it does work, we can support multiple platforms and make the modules easier to maintain because we have a single implementation instead of 3 different implementations.

The last thing I’ll say is, always test on all supported platforms. No matter how confident we are, there’s always be going to be inconsistencies, and it’s more work to fix if we find the bugs late.

<rte-button>Need to conduct React Native training in your company? Talk to us!<rte-button>

Responsive Design

Responsive design, it’s a pretty big thing on the web. But we don’t talk about it in React Native often, and it’s ignored in many apps. I see a lot of apps locking their orientation to portrait and it makes me sad.

There are many other features which won’t work properly if the app is not responsive. For example:

  • Screen orientation
  • Split screen
  • Free-form window mode

In split-screen mode, the user can render apps side by side. Another one is free-form window mode, mainly useful for tablet devices and Chromebook. Here the app windows can be freely resized like a desktop app window.

Today in React Native, it’s not easy to build responsive layouts. The available APIs don’t encourage building responsive layouts, and it’s often a magnitude easier not to make the UI responsive.

But there are some basic rules we can follow to make our layouts responsive,

  • Avoid <rte-code>Dimensions<rte-code> API
  • Use flexbox when possible
  • If you really need layout, use <rte-code>onLayout<rte-code>
  • Keep in mind that <rte-code>onLayout<rte-code> is async

Sometimes you do need the layout, for example, to do some calculations or conditional logic., React Native also has an onLayout API that you can pass to a View to get its layout. Just keep in mind that this is asynchronous, and you might need to do something like fading in the content after the layout is available for better user experience.

I had a similar issue in my tab view library, where I need to know the width of the tab view to render screens side by side. I didn’t want to fade in the content and wanted to make the wait for the layout invisible to the user. So I did some trickery to achieve this.

On the first render, I only render one screen and position it absolutely. This doesn’t require me to specify any width for the screen. When the layout is available, I remove the absolute position and use flexbox to position them. This is entirely transparent to the user.

screenshot presenting StyleSheet.absoluteFill in React Native

As you can see in the GIF, the tabview renders normally and supports changes in its layout, such as orientation. I’m sure you can also come up with more such tricks for your apps.

gif presenting layout orientation in react native

Accessibility

Accessibility is another important aspect to focus on. Accessibility simply means building to optimize access. We should be inclusive about giving equal access and opportunities to everyone wherever possible. Many people rely on assistive technologies to use apps and websites. If our apps are not accessible, we’re making it impossible for them to use.

Component libraries are building blocks, so it’s crucial to have them accessible by default. If the building blocks aren’t accessible, the app built with them won’t be either. This is why we are taking accessibility seriously with React Native Paper.

Let’s talk about some of the common disabilities.

Visual impairments

  • Blindness
  • Low-level vision
  • Color blindness

Hearing impairments

  • People with low or no hearing ability
  • Language disorders

Mobility impairments

  • Physical issues
  • Neurological or genetic disorders

I’ll mostly talk about visual impairments because that’s what we deal with most of the time when building apps. People with visual impairments often use screen readers to interact with apps. A screen reader lets them know what’s on the screen and allows them to interact with the app via certain gestures.

Most operating systems have built-in screen readers:

  • TalkBack on Android
  • VoiceOver on iOS and Mac
  • Narrator on Windows
  • Orca on Linux
  • ChromeVox on ChromeOS
  • Many more…

The best way to know if our components work with screen readers is to try to use them with screen readers. We can use the built-in screen readers in the OS to test our components on various devices. On iOS simulator, we can use the Accessibility Inspector tool provided with XCode.

screenshot presenting accessibility inspector in react native

Accessibility inspector will show all of the attached accessibility related info regarding a particular element. For example, here, the inspector is showing that our button has the appropriate accessibility role of the button and its label is “undo”.

React native provides several APIs to add accessibility related data. Such as <rte-code>accessibilityLabel<rte-code>, <rte-code>accessibilityHint<rte-code>, <rte-code>accessibilityRole<rte-code>, <rte-code>accessibilityStates<rte-code> and more.

To ensure accessibility by default,

  • Use semantic elements and appropriate roles
  • Use captions for media such as images, and videos
  • Make your web app accessible to keyboard users
  • Use enough contrast for colors and test for color blindness

Right-to-left languages

We just talked about making our components accessible. This also includes people who use a different language, which gets us to “right to left languages”, known as RTL in short. What is RTL? When we write English or polish, we write and read them from left to right. But there are many languages which are written and read from right to left.

In a region with an RTL language, books open from the right-hand side. Similarly, most UI elements are mirrored when using an RTL language.

Here is an example screenshot in an Arabic script. Most UI elements are flipped here, the icons are moved to the right, the text is aligned to right instead of left, etc.

rtl accessibility in react native

In most cases, React Native automatically handles RTL for us when we’re using flexbox. There will be some cases where we might want to handle it manually. React Native provides all the necessary APIs to test and implement these.

The <rte-code>I18nManager.forceRTL<rte-code> API changes your app to render in RTL mode so you can see how everything looks when using RTL languages. When you call this API, you’ll need to close your app and open it again.

The <rte-code>I18nManager.isRTL<rte-code> API is a boolean that tells us if we’re in RTL mode. We can implement RTL specific UI changes using this API.

Keep in mind that you would need to restart the app for RTL related changes to take effect.

Linking

This one is every React native developer’s favorite, linking. If a library includes native code, we often need to link it to use it. But unfortunately, it doesn’t work properly with many libraries.

So, if you’re building a library, always test that it works properly with <rte-code>react-native link<rte-code>. It’ll save many developers countless hours of struggle.

Fortunately, soon we’ll be able to have the ability to link libraries without any work on the user’s part.

Documentation

Documentation is one of the most important parts of a library. Good documentation makes happy users. However, writing and maintaining documentation can be a lot of work.

I love to automate things that can be automated. With the limited time I have, the fewer things I have to worry about, the better. I like generating documentation from code because it reduces the amount of work we have to do as maintainers, and there’s way less chance of the documentation getting out of date from the actual code.

It’s true that a lot of generated documentation is really bad. In my opinion, it’s not because they are generated, but because they don’t receive much attention. Even though I’m a fan of documentation generation, I like to write detailed comments for specific props so it’s actually understandable. Some topics require more detailed guides, which I like to put them in their own files.

Approaches

  • Extract code comments with React docgen
  • Write documentation in separate markdown files
  • Document props with code comments + detailed guides in markdown files

For React Native Paper, we follow this hybrid approach, where we extract documentation for props from code comments and flow types using react docgen, as well as writing guides for broader topics.

Our code comments look kind of like this. There are flow or typescript types with comments that will be extracted to the documentation pages.

Tools

When writing documentation, another important thing is to provide runnable playgrounds. This lets users quickly try out components, and also makes it easier to report issues.

Online playgrounds

Each of our code snippets in the usage examples have a “Try on Snack” link which loads that example in a full editor on Snack. It’s pretty easy to implement too, you can pass the full code in a query param to the snack website and it’ll load it in the editor.

gif presenting bottom navigation in react native

Static types

Static types are great. They help me by providing autocompletion and checking errors in my code. You should definitely use them in your project.

So, there are 2 popular static type checkers, Flow and TypeScript. Both have their own advantages. I’ll quickly compare both so we know which one is better for building libraries.

Flow

Flow is not 1.0 yet. It has breaking changes in each release. It means it’s a lot of work to keep it working every release. Due to this reason, React Native versions are coupled to specific Flow versions. So there are a lot of cons:

  • Breaking changes in each release
  • React Native versions coupled to Flow versions
  • No good workflow for libraries

There is also no good workflow for supporting multiple Flow versions except publishing on flow-typed. This would’ve been okay if there weren’t breaking changes each release, but right now the reality is that it’s not always possible to support multiple Flow versions with a single definition.

Even if you’re willing to publish definitions to flow-typed, it’s a lot of work, and Flow doesn’t support extracting type definitions from your existing code.

None of this would be a big issue in apps. But when working with libraries, we need to support different kind of projects which will have different versions of Flow.

TypeScript

TypeScript is stable and rarely has breaking changes. Other advantages include:

  • Stable and less breaking changes
  • CLI extracts definitions from source code
  • IDE provides intellisense even when a user doesn’t use TypeScript

There are of course many other differences, but these are the main things that stand out from a library development point of view. To me, TypeScript is a clear winner for libraries. We used to use Flow in React Navigation, but due to all the issues we removed it, and we want to migrate to TypeScript soon (pull request welcome by the way).

What’s more? Metro supports compiling TypeScript by default in the generated app, so there’s no reason not to use TypeScript.

Code quality

For ensuring code quality, I like these tools:

Publishing

So we have made sure of everything. How do we get this amazing library into the hand of users? It’s time to publish the package to npm.

Our libraries have a lot of files. Code, configuration, documentation, tests and many more. But we don’t want to publish all the files to keep the install size minimal.

What to publish?

  • Source code for Metro (React Native)
  • ES modules build for bundlers like Webpack
  • CommonJS build for everything else
  • Type definition files

There are 2 ways to tell npm what to publish, npmignore field where we list the files we don’t want to publish, and the files field to list the files we want to publish. I personally prefer to use the files key to keep things explicit.

If you have a React Native library, all you need to do is install @react-native-community/bob, and run yarn bob init to configure your project.

Checkout this article to know more about Bob.

Publishing can be a lot of work. We have to create a tag, create a release on GitHub, publish a changelog and finally publish the package to npm. I use a tool called release-it which automates all of these.

You can even use it on the CI to publish a new version automatically on every commit to master. There is another tool called semantic release which is very similar.

One last thing

Remember, it’s easy to add a new feature, but hard to remove it. Don’t put everything in your component library. It’s okay to write custom components for specific use cases.

You can tweet to me @satya164 if you want to chat about this topic or want to get started with contributing to Open Source. If you want to work with me, be sure to apply on our careers page. You can also check out services offered by our React Native development company.

Author:
Satyajit Sahoo
React Native and Web developer who specializes in JavaScript, TypeScript, and all things frontend related. Satya has created and maintained many open source libraries for React Native & Web such as React Navigation, React Native Paper, React Native Builder Bob, Linaria etc. Creator of React Navigation 5 and Linaria. When not coding, Satya loves cooking or playing video games.
arrow icon
MORE posts from this author
The super app landscape

What are super apps?

arrow-down

Super apps are multipurpose platforms that integrate a wide range of services and features to answer diverse user needs, all within a single mobile interface. Comprised of modular mini apps that users can activate at their convenience, super apps are the software equivalent of Swiss army knives that deliver a powerful mobile-first experience.

Super apps act as a one-stop shop for customers, allowing them to perform everyday tasks like shopping, paying bills, communicating, and more, all in one place. They’re a powerful tool for businesses looking to captivate users with what Mike Lazaridis, Blackberry founder who coined the term in 2010, defined as a “seamless, integrated, contextualized and efficient experience.”

A good example of such an all-round experience is WeChat, a multipurpose app developed in China. Its core features include messaging, localization, a search engine, a news feed, payments, loans, public services, transportation, and housing – and that’s by no means a finished list. It shouldn’t be surprising that the number of active users on WeChat is estimated to reach 1.102 billion by 2025.

What do super apps offer?

arrow-down

Super apps are made to meet the modern-day demand for smooth, convenient, all-encompassing mobile experiences. What makes them stand out, however, is the way they’re built and how they work. 

Ordinary mobile products offer a variety of features within a single application. Super apps, on the other hand, operate as a platform to deliver modular mini apps that users can activate for personalized experiences. The things that account for the super quality in super apps include:

  • range of services – while a mobile application typically serves a single purpose, a super app aims to be the only piece of software a user needs to perform a variety of actions across services or even industries, like Grab, WeChat, or Gojek.
  • all-in-one toolkit – traditional suites of applications released by tech giants like Google or Microsoft require users to switch between products to access different services. Super apps, on the other hand, shorten the customer journey by allowing users to achieve different goals within a single ecosystem without downloading multiple digital products.
  • data sharing – as opposed to ordinary apps that collect data related to a specific purpose only, super apps gather and process much more user data. While this may raise privacy and security concerns, properly-handled data sharing between respective services is a safe way to ensure an even smoother user experience.
  • financial services – there are limitless combinations of services that super apps may offer, from messaging, social networking, and e-commerce to transportation and health. However, as the examples of Gojek’s GoPay or WeChat Pay within WeChat Wallet show, built-in payment is one of the most prevalent. Super app users are usually required to provide their payment information only once for cross-service transactions – and they don’t need to leave the app to finalize the payment.

What’s the global landscape of super apps?

arrow-down

Ever since the launch of WeChat in 2011, super apps have been on the rise. There has been a notable difference between the emerging and developed economies’ approach to this kind of digital products, though. 

Super apps have taken emerging markets by storm. Among the most notable all-in-one applications released in the last decade are Southeast Asia's leading platforms Grab and MoMo, Latin America-based Rappi, Middle East’s first super app Careem, and WhatsApp, which started turning into a super app in Brazil by launched in-app business directory and shopping features. There are a few reasons why super apps have been booming in developing countries:

  • mobile-first nations – the emerging economies didn’t experience the desktop revolution the same way the developer markets did. Only once smartphones hit the market did they get to easily access the internet, which made many Asian nations mobile-first consumers and contributed to the wide adoption of super apps.
  • unbanked population – a large percentage of unbanked populations was the issue that the emerging economies have struggled with for a long time. To give you an idea, in 2018, over 220 million adults in China, 190 million in India, and 99 million in Pakistan didn’t have a bank account. With financial services often lying at their core, super apps allow users to access their assets and make purchases through mobile devices.
  • regulators’ support – governments in emerging economies have been supporting super apps to drive technological advancement together. For example, WeChat’s been subsidized by the Chinese government since its creation in 2011, while Jakarta entered into a partnership with Grab, Gojek, and other local startups to accelerate the launch of the capital’s smart city project. 

While super apps have been proliferating across emerging markets, they’ve been struggling to gain traction in the West. Among the reasons why are:

  • consumers’ concerns with data security and privacy,
  • rigid data sharing and antitrust laws,
  • cut-throat competition between existing players in most verticals.

What does the super app market look like now, and how will it evolve?

arrow-down

As of early 2023, 68% of the world’s population uses a mobile phone. Over the past year, the community of mobile users grew by 168 million individuals, and over 92% of all consumers use a mobile device to access the internet. These trends make the future look bright for businesses behind all sorts of mobile applications, including super apps, and translate into some promising numbers:

  • In 2022, the global super apps market size was valued at 61.30 billion U.S. dollars and was expected to expand at a compound annual growth rate of 27.8% until 2030. 
  • Gartner predicts that by 2027, over half of the population will be using multiple super apps daily, and their adoption will take place on both personal and enterprise levels. 
  • The survey conducted by statistics bureaus of the US, UK, Germany, and Australia estimated the number of potential day-one users for super apps is estimated to reach 98 million, which would result in an estimated 3.25 trillion U.S. dollars in annual spending on a super app by early-adoption users.

Super apps are widely adopted in Asia, the Middle East, Latin America, and Africa, but developed economies aren’t exempt from this global tech trend. The key to success in the US and Europe is to understand the distinctive needs and qualities of the Western markets. Having that in mind, Deloitte proposed the following direction for super apps in developed countries:

  • Having an established brand with developed user trust will make the organization’s entry into the super app ecosystem smoother, which seems promising for medium businesses and enterprises.
  • While banking and insurance-related features are indispensable in super apps, social media, ride-share, and payment companies are more likely to succeed in the Western market.
  • Unlike in the emerging economies, in the West, it seems unlikely to have one dominant super app; instead, we’re more likely to witness the rise of vertical-specific super apps, which means more opportunities for business growth.
  • Western super apps won’t aim to oust traditional mobile apps, and their competitive advantage is more likely to rely on giving users the ability to “manage fewer accounts, transact faster through consistent payments, save money using loyalty and rewards, and experience a better product enabled by cross-service insights and advice.”
  • Bearing in mind data privacy concerns, super apps targeted at the developed economies’ consumers will likely be more transparent about data use, and their functioning may require closer collaboration with regulators on the business's side.
  • The US and Europe won’t focus on the B2C market alone; we’re likely to witness there the emergence of more B2B super apps that will drive value “through data-driven insights, automated advice, and seamless integration of businesses’ platforms into a single workspace.”
Business impact of super apps

What are the business benefits of super apps?

arrow-down

Super apps have dominated emerging markets, and it’s only a matter of time before their popularity grows in the West. If you’re still wondering if your organization should jump on the super app bandwagon, consider the following business benefits:

  • increased customer acquisition – compared to traditional mobile applications, super apps offer a much wider range of services that cater to the needs of diverse audiences, which translates into a bigger potential user base. As your super app grows, it’s also possible to convert the existing users into consumers of a new service at practically zero cost, much like Gojek did.
  • improved user engagement – providing consolidated services in one place and consistently expanding the offering with new features gives you more touchpoints for interaction with users and makes it easier to keep them engaged. In the words of Dara Khosrowshahi, Uber’s CEO, “when we see customers using more than one product, their engagement with the platform more than doubles.” All of that boils down to bigger profits.
  • business stability and sustainable growth – this benefit relates to the ones we’ve already discussed, but it’s worth paying special attention to it due to the current economic landscape. Super apps embrace vertical growth by encouraging a shift from a product to a platform mindset. Offering a range of services may help your business survive when a given vertical suffers from an unexpected breakdown, as was the case with travel during the pandemic. 
  • increased revenue – services within the super app ecosystem can be provided by either you as the app owner or the third-party partners. Opening up your space to various retailers lets you monetize your product easily.
  • faster bug fixing – you can release fixes and improvements Over The Air (OTA), which means no hassle with Google Play or App Store review processes. Thanks to super app configuration, mini apps can download and install updates instantly without rebuilding the whole app.
  • team independence and development efficiency – while developing super apps in separate repositories, the host of the super app provides the necessary tools and infrastructure. The teams can work independently, which results in faster development, fewer code conflicts, and increased ownership in product teams.
  • security despite users’ concerns with data privacy, a super app is a sandbox where developers can play without breaking anything. You can build an environment where you mock some sensitive parts of your codebase. As a result, the environment is more secure, and external providers can move faster and contribute features to your app.

What makes super apps popular with users?

arrow-down

Super apps collectively have over 2.4 billion active users all over the world. Their enormous popularity in the B2C market can be attributed to:

  • ability to coordinate different aspects of everyday life in one place,
  • convenience and engaging experience without the need to learn how to use multiple apps,
  • time and storage saving resulting from having one user profile and downloading a single app for all services,
  • minimized risk of losing sensitive information when switching between service providers.

These benefits speak to those who haven’t yet had a chance to use a super app. According to a report by PYMNTS and PayPal, seven in ten global consumers express interest in a solution allowing them to manage payments and other everyday activities through a centralized tool. There’s much untapped potential in the developed economies, so why not be among the first to unlock it?

What are the concerns and challenges that come with super apps?

arrow-down

While super apps offer numerous benefits to both businesses and consumers, they come with some serious challenges as well:

  • data privacy – the multitude of services available within super apps is actually a mixed blessing for many users, especially in the West. Having heard hundreds of stories about data privacy abuse and data breaches from big tech companies, consumers are hesitant to share all their personal data with a single service provider, even if it comes with invaluable benefits.
  • regulatory issues – as a result of data privacy infringements, regulators around the world are implementing laws to further protect personal data and restrict sharing of user data between service providers. Another challenge for businesses behind super apps may be the competition legislations adopted in developed economies.  
  • user experience – in terms of UX, the main challenge for the teams behind the mini apps that make the super app is to strike a balance between consistency and uniqueness. On the one hand, the consistent look and feel account for a positive user experience, drive adoption and retention, and foster a sense of safety. On the other, super apps by definition are made to cater to the diverse needs of heterogeneous audiences, all at once. As each demographic segment interacts with digital products differently, the question remains how to maximize usability without overcomplicating the user experience.
Super apps and your organization

What does moving into the super app ecosystem mean for your organization?

arrow-down

Digital products are not developed in a vacuum. The way they’re designed and operate depends on many factors, one of which is communication between the development team. 

As stated by Melvin E. Conway: "Any organization that designs a system (defined broadly) will produce a design whose structure is a copy of the organization's communication structure." In simple words, Conway’s law means that the organizational structure is often mirrored in software design. For example, large corporations still using legacy technologies are much more likely to build stiff monoliths – and so their product reflects the organizational concerns more than the actual user needs.

A tool to tackle this issue is the reverse Conway maneuver, according to which the desired software architecture is what affects the organizational structure, not the other way round. This way, teams are capable of building digital products optimized for changing user requirements and business objectives, just as is the case with super app development.

The super app approach has a profound impact on how you organize the work of your developers. It enables respective teams to independently develop and deploy parts of the host application as mini apps and gives more room for third-party contributions. The way the super app architecture influences team composition and the development process is a great example of the reverse Conway law in practice.

What should you consider when choosing a super app development partner?

arrow-down

Hiring a tech partner to build your super app can be a real money and time-saver. It takes the burden of internal recruitment from you if you lack in-house expertise in this area and opens up possibilities for upskilling. When looking for a reliable super app development company, we advise looking for the following qualities:

  • experience building super apps – it may sound obvious, but checking if the tech partner’s portfolio includes projects like yours is key. Super apps are a special kind of mobile applications, so the software development company of your choice should know its way around building mini apps and integrating them into whole ecosystems. If you’re wondering about our experience, check out how we improved the performance of MoMo’s super app and mini apps by migrating their architecture to Re.Pack
  • consultancy approach – what sets a good tech partner apart from ordinary outsourced teams is proactivity in matching tech solutions with your needs. You should be looking for a company that’s eager to take a closer look at your current product and situation first, without assessing it as good or bad, but focusing on the potential for improvement. Only once the tech partner understands your pain points and objectives better can they suggest a bespoke mix of technology and solutions. 
  • going beyond development – stepping into the super app ecosystem is not a purely technical choice; it also entails a certain degree of organizational change. That’s why the right tech partner should be able to outline the product roadmap and propose relevant changes to processes, workflows, and peopleware.
  • knowledge-sharing – if your in-house team doesn’t have much experience building super app ecosystems, it might be a good idea to look for a tech partner whose developers will share their specialist knowledge with your squad. This will make the long-term development work more efficient and lay the foundations for sustainable business growth.

At Callstack, we’ve got super app development skills and a business-oriented proactive approach. Get in touch with us, and let’s find out how we can help your business succeed with the next big super app.

Super app development in practice

What are key tech considerations for super app development?

arrow-down

The unique experience that super apps offer comes with some special development considerations. Here’s a brief overview of the main factors, which you can read more about in the tech FAQ:

  • tech stack – there’s no one-size-fits-all solution to building a robust and sustainable super app, so you can go for native or cross-platform development, depending on your needs and capabilities. Our experience shows that choosing React Native and Re.Pack means optimal user experience and the ability to leverage code splitting for streamlined development and simplified management of your super app.
  • consistent performance – whether you’re in charge of all services or you’re cooperating with a third-party partner, all functionalities within your super app should have equal operating speed and effectiveness, even on low-end devices and in the low-speed internet environment.
  • user-friendly design – the abundance of features can be overwhelming unless you minimize the friction with a consistent design. To captivate the users, your super app’s design should be visually appealing yet clean and intuitive, especially if you’re planning to win the hearts of Western users, who are accustomed to straightforward navigation and minimalist design.
  • security ensuring user safety should be a priority for every tech business; however, with super apps storing all personal information in one place, their creators should put in even more effort to prevent security breaches. The precautions your development team can take include pen tests, 2FA, code obfuscation, data encryption, and more.

What approach to super app development can you adopt? 

arrow-down

Digital products come in all shapes and sizes, which is why the common answer to many questions in software development is “it depends”. Super app development is no different, as depending on your preferences, you can choose from the following approaches:

  • Native Android application with Feature Delivery
  • Native iOS application with WebViews
  • Cross-platform React Native application with Metro
  • Cross-platform React Native application with Webpack and Re.Pack

At Callstack, though, we recommend going for the latter because it proves to be the most beneficial. Compared to other tools and solutions available on the market, Re.Pack allows you to enjoy:

  • reusable features
  • smaller JS bundle size
  • OTA updates of on-demand features
  • time and cost-effective development experience
  • ability to leverage third-party contributions

If you’re wondering how it works in practice, we encourage you to check out our super-app-showcase.

What exactly is Callstack’s super-app-template?

arrow-down

Our super-app-showcase is a repository demonstrating how to structure a super app when working with Re.Pack and Module Federation to achieve the best business results. It highlights various solutions and best practices developers can employ to tackle challenges and streamline the super app development process. 

The super-app-showcase comprises:

  • the host app, which is the main container for the micro-frontends,
  • the shell app, which functions like a blueprint of the host app with shared dependencies,
  • a few mini apps, each dedicated to a single service booking, shopping, dashboard, and news – the latter being stored in a separate repository. 

You can learn more about the architecture and the intricacies of the template from the case study published on our blog.

How does super app development with Callstack's super-app-template influence your team’s work and developer experience?

arrow-down

By definition, a super app is built as a platform “to deliver a mini apps ecosystem that users can choose from to activate for consistent and personalized app experiences.” This modular approach allows a large development team to split into smaller squads, each focused on a respective mini app, and enables third-party contributions to be seamlessly integrated into the final product. 

When implemented right, such a workflow may lead to greater flexibility, independence, and development speed. Among the steps to optimize developer experience in the super app setup, there are:

  • creating and exposing a sandbox environment that closely resembles your host app, like the shell app in our super-app-showcase,
  • if need be, creating an SDK that contains common and repeatedly used elements,
  • organizing the codebase into a monorepo, which is an optional step.

Using Re.Pack and our super-app-template to build your super app makes the application of these tips in developers’ work much easier.

The super app landscape
Business impact of super apps
Super apps and your organization
Super app development in practice

What are super apps?

arrow-down

Super apps are multipurpose platforms that integrate a wide range of services and features to answer diverse user needs, all within a single mobile interface. Comprised of modular mini apps that users can activate at their convenience, super apps are the software equivalent of Swiss army knives that deliver a powerful mobile-first experience.

Super apps act as a one-stop shop for customers, allowing them to perform everyday tasks like shopping, paying bills, communicating, and more, all in one place. They’re a powerful tool for businesses looking to captivate users with what Mike Lazaridis, Blackberry founder who coined the term in 2010, defined as a “seamless, integrated, contextualized and efficient experience.”

A good example of such an all-round experience is WeChat, a multipurpose app developed in China. Its core features include messaging, localization, a search engine, a news feed, payments, loans, public services, transportation, and housing – and that’s by no means a finished list. It shouldn’t be surprising that the number of active users on WeChat is estimated to reach 1.102 billion by 2025.

What do super apps offer?

arrow-down

Super apps are made to meet the modern-day demand for smooth, convenient, all-encompassing mobile experiences. What makes them stand out, however, is the way they’re built and how they work. 

Ordinary mobile products offer a variety of features within a single application. Super apps, on the other hand, operate as a platform to deliver modular mini apps that users can activate for personalized experiences. The things that account for the super quality in super apps include:

  • range of services – while a mobile application typically serves a single purpose, a super app aims to be the only piece of software a user needs to perform a variety of actions across services or even industries, like Grab, WeChat, or Gojek.
  • all-in-one toolkit – traditional suites of applications released by tech giants like Google or Microsoft require users to switch between products to access different services. Super apps, on the other hand, shorten the customer journey by allowing users to achieve different goals within a single ecosystem without downloading multiple digital products.
  • data sharing – as opposed to ordinary apps that collect data related to a specific purpose only, super apps gather and process much more user data. While this may raise privacy and security concerns, properly-handled data sharing between respective services is a safe way to ensure an even smoother user experience.
  • financial services – there are limitless combinations of services that super apps may offer, from messaging, social networking, and e-commerce to transportation and health. However, as the examples of Gojek’s GoPay or WeChat Pay within WeChat Wallet show, built-in payment is one of the most prevalent. Super app users are usually required to provide their payment information only once for cross-service transactions – and they don’t need to leave the app to finalize the payment.

What’s the global landscape of super apps?

arrow-down

Ever since the launch of WeChat in 2011, super apps have been on the rise. There has been a notable difference between the emerging and developed economies’ approach to this kind of digital products, though. 

Super apps have taken emerging markets by storm. Among the most notable all-in-one applications released in the last decade are Southeast Asia's leading platforms Grab and MoMo, Latin America-based Rappi, Middle East’s first super app Careem, and WhatsApp, which started turning into a super app in Brazil by launched in-app business directory and shopping features. There are a few reasons why super apps’ have been booming in developing countries:

  • mobile-first nations – the emerging economies didn’t experience the desktop revolution the same way the developer markets did. Only once smartphones hit the market did they get to easily access the internet, which made many Asian nations mobile-first consumers and contributed to the wide adoption of super apps.
  • unbanked population – a large percentage of unbanked populations was the issue that the emerging economies have struggled with for a long time. To give you an idea, in 2018, over 220 million adults in China, 190 million in India, and 99 million in Pakistan didn’t have a bank account. With financial services often lying at their core, super apps allow users to access their assets and make purchases through mobile devices.
  • regulators’ support – governments in emerging economies have been supporting super apps to drive technological advancement together. For example, WeChat’s been subsidized by the Chinese government since its creation in 2011, while Jakarta entered into a partnership with Grab, Gojek, and other local startups to accelerate the launch of the capital’s smart city project. 

While super apps have been proliferating across emerging markets, they’ve been struggling to gain traction in the West. Among the reasons why are:

  • consumers’ concerns with data security and privacy
  • rigid data sharing and antitrust laws
  • cut-throat competition between existing players in most verticals.

What does the super app market look like now, and how will it evolve?

arrow-down

As of early 2023, 68% of the world’s population uses a mobile phone. Over the past year, the community of mobile users grew by 168 million individuals, and over 92% of all consumers use a mobile device to access the internet. These trends make the future look bright for businesses behind all sorts of mobile applications, including super apps, and translate into some promising numbers:

  • In 2022, the global super apps market size was valued at 61.30 billion U.S. dollars and was expected to expand at a compound annual growth rate of 27.8% until 2030. 
  • Gartner predicts that by 2027, over half of the population will be using multiple super apps daily, and their adoption will take place on both personal and enterprise levels. 
  • The survey conducted by statistics bureaus of the US, UK, Germany, and Australia estimated the number of potential day-one users for super apps is estimated to reach 98 million, which would result in an estimated 3.25 trillion U.S. dollars in annual spending on a super app by early-adoption users.

Super apps are widely adopted in Asia, the Middle East, Latin America, and Africa, but developed economies aren’t exempt from this global tech trend. The key to success in the US and Europe is to understand the distinctive needs and qualities of the Western markets. Having that in mind, Deloitte proposed the following direction for super apps in developed countries:

  • Having an established brand with developed user trust will make the organization’s entry into the super app ecosystem smoother, which seems promising for medium businesses and enterprises.
  • While banking and insurance-related features are indispensable in super apps, social media, ride-share, and payment companies are more likely to succeed in the Western market.
  • Unlike in the emerging economies, in the West, it seems unlikely to have one dominant super app; instead, we’re more likely to witness the rise of vertical-specific super apps, which means more opportunities for business growth.
  • Western super apps won’t aim to oust traditional mobile apps, and their competitive advantage is more likely to rely on giving users the ability to “manage fewer accounts, transact faster through consistent payments, save money using loyalty and rewards, and experience a better product enabled by cross-service insights and advice.”
  • Bearing in mind data privacy concerns, super apps targeted at the developed economies’ consumers will likely be more transparent about data use, and their functioning may require closer collaboration with regulators on the business's side.
  • The US and Europe won’t focus on the B2C market alone; we’re likely to witness there the emergence of more B2B super apps that will drive value “through data-driven insights, automated advice, and seamless integration of businesses’ platforms into a single workspace.”

What are the business benefits of super apps?

arrow-down

Super apps have dominated emerging markets, and it’s only a matter of time before their popularity grows in the West. If you’re still wondering if your organization should jump on the super app bandwagon, consider the following business benefits:

  • increased customer acquisition – compared to traditional mobile applications, super apps offer a much wider range of services that cater to the needs of diverse audiences, which translates into a bigger potential user base. As your super app grows, it’s also possible to convert the existing users into consumers of a new service at practically zero cost, much like Gojek did.
  • improved user engagement – providing consolidated services in one place and consistently expanding the offering with new features gives you more touchpoints for interaction with users and makes it easier to keep them engaged. In the words of Dara Khosrowshahi, Uber’s CEO, “when we see customers using more than one product, their engagement with the platform more than doubles.” All of that boils down to bigger profits.
  • business stability and sustainable growth – this benefit relates to the ones we’ve already discussed, but it’s worth paying special attention to it due to the current economic landscape. Super apps embrace vertical growth by encouraging a shift from a product to a platform mindset. Offering a range of services may help your business survive when a given vertical suffers from an unexpected breakdown, as was the case with travel during the pandemic. 
  • increased revenue – services within the super app ecosystem can be provided by either you as the app owner or the third-party partners. Opening up your space to various retailers lets you monetize your product easily.
  • faster bug fixing – you can release fixes and improvements Over The Air (OTA), which means no hassle with Google Play or App Store review processes. Thanks to super app configuration, mini apps can download and install updates instantly without rebuilding the whole app.
  • team independence and development efficiency – while developing super apps in separate repositories, the host of the super app provides the necessary tools and infrastructure. The teams can work independently, which results in faster development, fewer code conflicts, and increased ownership in product teams.
  • security despite users’ concerns with data privacy, a super app is a sandbox where developers can play without breaking anything. You can build an environment where you mock some sensitive parts of your codebase. As a result, the environment is more secure, and external providers can move faster and contribute features to your app.

What makes super apps popular with users?

arrow-down

Super apps collectively have over 2.4 billion active users all over the world. Their enormous popularity in the B2C market can be attributed to:

  • ability to coordinate different aspects of everyday life in one place,
  • convenience and engaging experience without the need to learn how to use multiple apps,
  • time and storage saving resulting from having one user profile and downloading a single app for all services,
  • minimized risk of losing sensitive information when switching between service providers.

These benefits speak to those who haven’t yet had a chance to use a super app. According to a report by PYMNTS and PayPal, seven in ten global consumers express interest in a solution allowing them to manage payments and other everyday activities through a centralized tool. There’s much untapped potential in the developed economies, so why not be among the first to unlock it?

What are the concerns and challenges that come with super apps?

arrow-down

While super apps offer numerous benefits to both businesses and consumers, they come with some serious challenges as well:

  • data privacy – the multitude of services available within super apps is actually a mixed blessing for many users, especially in the West. Having heard hundreds of stories about data privacy abuse and data breaches from big tech companies, consumers are hesitant to share all their personal data with a single service provider, even if it comes with invaluable benefits.
  • regulatory issues – as a result of data privacy infringements, regulators around the world are implementing laws to further protect personal data and restrict sharing of user data between service providers. Another challenge for businesses behind super apps may be the competition legislations adopted in developed economies.  
  • user experience – in terms of UX, the main challenge for the teams behind the mini apps that make the super app is to strike a balance between consistency and uniqueness. On the one hand, the consistent look and feel account for a positive user experience, drive adoption and retention, and foster a sense of safety. On the other, super apps by definition are made to cater to the diverse needs of heterogeneous audiences, all at once. As each demographic segment interacts with digital products differently, the question remains how to maximize usability without overcomplicating the user experience.

What does moving into the super app ecosystem mean for your organization?

arrow-down

Digital products are not developed in a vacuum. The way they’re designed and operate depends on many factors, one of which is communication between the development team. 

As stated by Melvin E. Conway: "Any organization that designs a system (defined broadly) will produce a design whose structure is a copy of the organization's communication structure." In simple words, Conway’s law means that the organizational structure is often mirrored in software design. For example, large corporations still using legacy technologies are much more likely to build stiff monoliths – and so their product reflects the organizational concerns more than the actual user needs.

A tool to tackle this issue is the reverse Conway maneuver, according to which the desired software architecture is what affects the organizational structure, not the other way round. This way, teams are capable of building digital products optimized for changing user requirements and business objectives, just as is the case with super app development.

The super app approach has a profound impact on how you organize the work of your developers. It enables respective teams to independently develop and deploy parts of the host application as mini apps and gives more room for third-party contributions. The way the super app architecture influences team composition and the development process is a great example of the reverse Conway law in practice.

What should you consider when choosing a super app development partner?

arrow-down

Hiring a tech partner to build your super app can be a real money and time-saver. It takes the burden of internal recruitment from you if you lack in-house expertise in this area and opens up possibilities for upskilling. When looking for a reliable super app development company, we advise looking for the following qualities:

  • experience building super apps – it may sound obvious, but checking if the tech partner’s portfolio includes projects like yours is key. Super apps are a special kind of mobile applications, so the software development company of your choice should know its way around building mini apps and integrating them into whole ecosystems. If you’re wondering about our experience, check out how we improved the performance of MoMo’s super app and mini apps by migrating their architecture to Re.Pack
  • consultancy approach – what sets a good tech partner apart from ordinary outsourced teams is proactivity in matching tech solutions with your needs. You should be looking for a company that’s eager to take a closer look at your current product and situation first, without assessing it as good or bad, but focusing on the potential for improvement. Only once the tech partner understands your pain points and objectives better can they suggest a bespoke mix of technology and solutions. 
  • going beyond development – stepping into the super app ecosystem is not a purely technical choice; it also entails a certain degree of organizational change. That’s why the right tech partner should be able to outline the product roadmap and propose relevant changes to processes, workflows, and peopleware.
  • knowledge-sharing – if your in-house team doesn’t have much experience building super app ecosystems, it might be a good idea to look for a tech partner whose developers will share their specialist knowledge with your squad. This will make the long-term development work more efficient and lay the foundations for sustainable business growth.

At Callstack, we’ve got super app development skills and a business-oriented proactive approach. Get in touch with us, and let’s find out how we can help your business succeed with the next big super app.

What are key tech considerations for super app development?

arrow-down

The unique experience that super apps offer comes with some special development considerations. Here’s a brief overview of the main factors, which you can read more about in the tech FAQ:

  • tech stack – there’s no one-size-fits-all solution to building a robust and sustainable super app, so you can go for native or cross-platform development, depending on your needs and capabilities. Our experience shows that choosing React Native and Re.Pack means optimal user experience and the ability to leverage code splitting for streamlined development and simplified management of your super app.
  • consistent performance – whether you’re in charge of all services or you’re cooperating with a third-party partner, all functionalities within your super app should have equal operating speed and effectiveness, even on low-end devices and in the low-speed internet environment.
  • user-friendly design – the abundance of features can be overwhelming unless you minimize the friction with a consistent design. To captivate the users, your super app’s design should be visually appealing yet clean and intuitive, especially if you’re planning to win the hearts of Western users, who are accustomed to straightforward navigation and minimalist design.
  • security ensuring user safety should be a priority for every tech business; however, with super apps storing all personal information in one place, their creators should put in even more effort to prevent security breaches. The precautions your development team can take include pen tests, 2FA, code obfuscation, data encryption, and more.

What approach to super app development can you adopt? 

arrow-down

Digital products come in all shapes and sizes, which is why the common answer to many questions in software development is “it depends”. Super app development is no different, as depending on your preferences, you can choose from the following approaches:

  • Native Android application with Feature Delivery
  • Native iOS application with WebViews
  • Cross-platform React Native application with Metro
  • Cross-platform React Native application with Webpack and Re.Pack

At Callstack, though, we recommend going for the latter because it proves to be the most beneficial. Compared to other tools and solutions available on the market, Re.Pack allows you to enjoy:

  • reusable features
  • smaller JS bundle size
  • OTA updates of on-demand features
  • time and cost-effective development experience
  • ability to leverage third-party contributions

If you’re wondering how it works in practice, we encourage you to check out our super-app-template.

What exactly is Callstack’s super-app-template?

arrow-down

Our super-app-template is a repository demonstrating how to structure a super app when working with Re.Pack and Module Federation to achieve the best business results. It highlights various solutions and best practices developers can employ to tackle challenges and streamline the super app development process. 

The super-app-template comprises:

  • the host app, which is the main container for the micro-frontends
  • the shell app, which functions like a blueprint of the host app with shared dependencies
  • a few mini apps, each dedicated to a single service booking, shopping, dashboard, and news – the latter being stored in a separate repository. 

You can learn more about the architecture and the intricacies of the template from the case study published on our blog.

What does the super app How does super app development with Callstack template influence your team’s work and developer experience? look like now, and how will it evolve?

arrow-down

By definition, a super app is built as a platform “to deliver a mini apps ecosystem that users can choose from to activate for consistent and personalized app experiences.” This modular approach allows a large development team to split into smaller squads, each focused on a respective mini app, and enables third-party contributions to be seamlessly integrated into the final product. 

When implemented right, such a workflow may lead to greater flexibility, independence, and development speed. Among the steps to optimize developer experience in the super app setup, there are:

  • creating and exposing a sandbox environment that closely resembles your host app, like the shell app in our super-app-template,
  • if need be, creating an SDK that contains common and repeatedly used elements,
  • organizing the codebase into a monorepo, which is an optional step.

Using Re.Pack and our super-app-template to build your super app makes the application of these tips in developers’ work much easier.

Bundle React Native apps using Webpack features

Discover Re.Pack – a Webpack-based toolkit that allows you to build a React Native app with the full support of the Webpack ecosystem.

learn more

More posts from this category

Ensure your React components perform as intended as your app grows

Discover Reassure - our open-source library that allows you to run performance tests measuring the average rendering time of the in-app components.

business benefits

Performance Optimization

To stay competitive, you need a high-performing app. Improving React Native performance can bring your company many business and tech benefits. To learn more about it, check the page entirely dedicated to React Native Performance Optimization. Discover a real-life example of React Native optimization we performed for Aaqua, a Singaporean platform that enables global users to share their passion through groups.

Bundle React Native apps using Webpack features

Discover Re.Pack – a Webpack-based toolkit that allows you to build a React Native app with the full support of the Webpack ecosystem.

business benefits

Why React Native?

Building an all-in-one platform can bring your company a lot of business and tech benefits like seamless UX experience, global reach, brand growth just to name a few. To learn more about the benefits of using React Native to develop super apps, check out the MoMo case study. Where we helped improve app's performance by migrating architecture to Re.Pack.

stay tuned

Subscribe to our newsletter

You may unsubscribe from these communications at any time. For details see the Privacy Policy.