Flutter or KMM

05/03/2024

First up, let’s set the scene. Picture this: A FinTech company had a vision to design a native mobile app for iOS and Android platforms that will transform users into personal finance wizards—tracking spending, setting budget goals, investing, and transferring money, all at their fingertips.

After a not-so-brief flirtation with available technologies, Kotlin Multiplatform Mobile and our developers had a “meet-cute”. KMM won hearts because it allowed the team to script common business logic for both platforms in Kotlin—a language they had already wooed and won over. KMM promised native performance and UX for both platforms—a non-negotiable in the FinTech world where performance and security are like a good espresso, robust and intense.

Favicon

Author: Kasia

Ktolin Flutter

Let the Journey begin!

When taking over a project, our priority is to assess the current state and adapt to the client’s needs. This involves analyzing the existing environment, conducting tests, and determining the necessary actions to execute a smooth transition.

A typical course of this process includes:

Icon code

Planning and Design

Our team began with a crystal-clear understanding of the business requirements and then designed a blueprint. They identified parts of the application that would share common business logic and those that would be platform-specific.

Icon code

Implementation of common business logic

KMM enabled our team to write the common business logic in Kotlin. This part included exciting tasks such as managing user data, bank account operations, transactions, investments, and more.

Icon code

Implementing platform-specific logic

Here, we got down to designing the user interface and other platform-specific features like push notifications, using native languages and tools for iOS and Android.

Icon code

Testing and Improvement

We’re not ones to brag, but our testing was as comprehensive as a three-course meal. This included unit, integration, and functional testing.

Icon code

Deployment and Support

Once we put the app through the wringer and it came out smiling, it was deployed on both platforms. The best part? It’s been regularly updated and improved.

Why not Flutter this time

While Flutter excels at fast prototyping and swiftly creating user interfaces with a single codebase, KMM stole the spotlight for a few solid reasons:

Icon code

Native Performance

Our team began with a crystal-clear understanding of the business requirements and then designed a blueprint. They identified parts of the application that would share common business logic and those that would be platform-specific.

Icon code

Kotlin

KMM enabled our team to write the common business logic in Kotlin. This part included exciting tasks such as managing user data, bank account operations, transactions, investments, and more.

Icon code

Integration with existing systems

Here, we got down to designing the user interface and other platform-specific features like push notifications, using native languages and tools for iOS and Android.

Icon code

Native integration with device APIs

We’re not ones to brag, but our testing was as comprehensive as a three-course meal. This included unit, integration, and functional testing.

Icon code

Multi-threading support

Once we put the app through the wringer and it came out smiling, it was deployed on both platforms. The best part? It’s been regularly updated and improved.

Now, don’t get me wrong, Flutter may still be the better match for different types of projects, especially those that need quick prototyping, have less complex performance requirements, or have teams that can converse in Dart better than in Kotlin.

While developing the app, we also turned a keen eye on features that needed a native touch – the camera, widgets, or Bluetooth.

Camera

If your app needs a camera for functions like document or QR code scanning, KMM gets two thumbs up.

Icon code

Native Camera API Integration

KMM gets VIP access to native camera APIs on each platform. This means it can get creative with the camera’s features like different shooting modes, focus control, white balance, etc. In contrast, Flutter depends on third-party packages to support the camera, which may not always deliver the full range of features or keep up with the latest API updates.

Icon code

Better Performance

With native access to the camera API, KMM can outperform Flutter when it comes to tasks such as image processing and analysis.

Icon code

Better UI Control

KMM grants developers full control over the camera UI, allowing them to tailor it to the specific app requirements while maintaining a native look on any platform.

Widgets

Home screen widgets are the charm of mobile apps, offering users quick access to key info and features without opening the app. In this area, KMM trumps Flutter:

Icon code

Native widget support

KMM speaks the native languages and tools for iOS and Android, guaranteeing full usage of native widget APIs. In contrast, Flutter lacks this native support and relies on libraries that may not always comply with iOS and Android UI guidelines.

Icon code

Updates and maintenance

With KMM, refreshing your widgets with the latest OS updates is effortless. But with Flutter, you’re at the mercy of the library developers to keep pace with the latest changes, which can introduce issues.

Icon code

Application integration

KMM integrates widgets with the rest of the app effortlessly, thanks to the shared code and tools. Conversely, Flutter may encounter difficulties because widgets need a different toolkit before integration with the rest of the app.

Bluetooth

Bluetooth is essential for many mobile apps, enabling smooth interactions with devices like headsets and smartwatches. Here’s why KMM takes the trophy in this round too:

Native Bluetooth API Support: KMM enjoys premium access to native Bluetooth APIs on each platform, allowing developers to fully exploit Bluetooth functionalities. On the other hand, Flutter relies on libraries that may lack the full suite of features and might experience stability or security issues.

Summary

Both KMM and Flutter have their strengths and weaknesses, and choosing the right framework is like picking the perfect ice cream flavor—it depends on individual project needs, developer tastes, and performance expectations.

KMM might be the perfect choice for those desiring a framework capable of creating apps with native performance while fully leveraging existing Kotlin libraries. Conversely, Flutter might attract developers aiming to create cross-platform applications rapidly and efficiently. Some sources suggest that Flutter can speed up the app development process by 30%-50%. Plus, it requires fewer team members for smaller projects, reducing project costs.

In the end, both KMM and Flutter have carved out their niches in the cross-platform applications market, continuing to prosper thanks to the support of their communities and parent companies. The decision between KMM or Flutter should be based on a comprehensive understanding of your project needs and the capabilities of both technologies.