KMP vs. Flutter - Who Will Win The Cross-Platform Battle?

Philipp Lackner
9 Jun 202416:18

Summary

TLDRIn this video, the host compares two leading cross-platform frameworks, Kotlin Multiplatform (KMP) and Flutter, for mobile app development. They delve into code sharing, programming languages, compilation processes, UI rendering, native API communication, performance, and maturity. The host, an Android developer, leans towards KMP due to its native capabilities and Google's official support, despite acknowledging Flutter's stability and widespread use. The video concludes with a recommendation for native Android developers to consider KMP, especially with Kotlin knowledge, while suggesting both frameworks will coexist, catering to different developer needs and goals.

Takeaways

  • ๐Ÿ“ฑ Cross-platform development has been a significant aspect of mobile platforms, with native development being equally prevalent.
  • ๐Ÿ” Two prominent frameworks for building iOS and Android apps with a single code base are KMP (Kotlin Multiplatform) and Flutter.
  • ๐Ÿ‘จโ€๐Ÿ’ป The speaker, a native Android developer with 5-6 years of experience, finds cross-platform frameworks appealing and will compare KMP and Flutter.
  • ๐Ÿ“ The comparison will cover various aspects including code sharing, programming languages, compilation, UI rendering, native API communication, performance, maturity, and future predictions.
  • ๐Ÿ”‘ Both KMP and Flutter support code sharing across iOS, Android, desktop apps, and web platforms.
  • ๐Ÿ’ฌ KMP uses Kotlin, while Flutter uses Dart, with the speaker expressing a preference for Kotlin's syntax and features over Dart.
  • ๐Ÿ”„ Compilation in KMP depends on the target platform, compiling to JVM byte code for Android, native binaries for iOS, and JavaScript for web.
  • ๐Ÿ–ผ๏ธ UI rendering in KMP can use native components or shared Jetpack Compose code, whereas Flutter uses a canvas-based approach without native components.
  • ๐Ÿค KMP allows direct interaction with native APIs through an expect-actual mechanism, while Flutter requires a bridge layer via platform channels.
  • โšก Theoretically, KMP may offer better performance due to the lack of a bridge layer, sharing the same memory space and call stack as the platform.
  • ๐Ÿ› ๏ธ KMP is considered stable and production-ready, but its UI component, Compose Multiplatform, is still in beta or alpha for non-Android platforms.
  • ๐Ÿ”ฎ The speaker speculates on the future, noting Google's official support for KMP and suggesting it might have a brighter future than Flutter, which is owned by Google.
  • ๐Ÿ“š For native Android developers familiar with Kotlin, transitioning to KMP is recommended due to the learning curve and Google's recent support.
  • ๐ŸŒ The speaker believes that both KMP and Flutter will coexist, catering to different developer preferences and project requirements.

Q & A

  • What are the two most popular cross-platform frameworks discussed in the video?

    -The two most popular cross-platform frameworks discussed in the video are Kotlin Multiplatform (KMP) and Flutter.

  • What are the main aspects compared in the video between KMP and Flutter?

    -The main aspects compared in the video are code sharing, programming language, compilation process, UI rendering, communication with native APIs, performance, maturity, future assumptions, and personal recommendations.

  • Which platforms can be targeted for development with both KMP and Flutter?

    -Both KMP and Flutter allow development for iOS, Android, desktop apps, and web platforms.

  • What programming language does Kotlin Multiplatform use?

    -Kotlin Multiplatform uses the Kotlin programming language.

  • What programming language does Flutter use and what is the speaker's opinion on it?

    -Flutter uses the Dart programming language. The speaker, being a native Android developer, finds Dart reminiscent of Java and lacking the syntactical sugar found in Kotlin.

  • How does the compilation process differ between KMP and Flutter?

    -KMP compiles shared Kotlin code to native binaries for each platform, including JVM bytecode for Android, while Flutter compiles to native machine code for each platform, but does not compile to JVM bytecode on Android, instead compiling directly to machine code.

  • How does UI rendering work in KMP and Flutter?

    -In KMP, UI components are drawn from scratch using a native canvas on each platform. Flutter, on the other hand, draws everything defined in Flutter on a canvas on all platforms without the option to write native UI components for each platform individually.

  • What is the difference in communication with native APIs between KMP and Flutter?

    -KMP can directly interact with native APIs without a bridge layer, using an expect-actual mechanism for platform-specific logic. Flutter, however, requires a bridge layer through platform channels to communicate with native APIs.

  • What does the speaker suggest about the performance of KMP and Flutter apps?

    -The speaker suggests that both KMP and Flutter apps are technically native and should have similar performance, but the lack of a bridge layer in KMP might make it slightly more performant.

  • What is the speaker's view on the maturity of KMP and Flutter?

    -The speaker considers KMP to be stable and production-ready, especially without Compose Multiplatform. Flutter is also stable and widely used but is maintained by Google, which the speaker suggests might not be as committed to it as JetBrains is to KMP.

  • What is the speaker's recommendation for a native Android developer interested in cross-platform development?

    -The speaker recommends that a native Android developer already familiar with Kotlin should consider learning KMP as it leverages their existing knowledge and has recently gained official support from Google.

  • What does the speaker predict about the future of KMP and Flutter?

    -The speaker predicts that both KMP and Flutter will coexist, with KMP having a bright future due to Google's official support and JetBrains' commitment to it, while Flutter, being a Google product, might not be as favored in the long term.

Outlines

00:00

๐Ÿ“ฑ Cross-Platform Frameworks: KMP vs. Flutter

The video introduces a comparison between two popular cross-platform mobile app development frameworks, Kotlin Multiplatform (KMP) and Flutter. The host, an experienced Android developer, expresses interest in cross-platform development and outlines the video's agenda, which includes discussing code sharing, programming languages, compilation processes, UI rendering, native API communication, performance, maturity, future prospects, and personal recommendations. Both KMP and Flutter are highlighted as capable of generating apps for iOS, Android, desktop, and web from a single code base.

05:01

๐Ÿ” Deep Dive into Programming Languages and Compilation

This paragraph delves into the programming languages used by each framework, with KMP utilizing Kotlin and Flutter using Dart. The host shares a personal bias towards Kotlin, finding Dart reminiscent of Java but lacking Kotlin's 'syntactical sugar.' The discussion then shifts to how each framework compiles shared code into platform-specific binaries. KMP compiles to JVM bytecode for Android, native binaries for iOS and desktop apps, and JavaScript for web apps. Flutter, while also producing native apps, compiles directly to machine code on Android, avoiding the JVM layer, and uses platform channels to communicate with native APIs, introducing a performance overhead compared to KMP's direct API access.

10:04

๐Ÿ–ผ๏ธ UI Rendering and Native API Interaction

The host compares UI rendering techniques of KMP and Flutter, noting that while both frameworks redraw UI components natively on each platform, KMP allows for the use of native UI components within a shared codebase, a flexibility not as straightforward in Flutter. When it comes to interacting with native APIs for platform-specific logic, KMP leverages an 'expect-actual' mechanism, enabling direct interaction with native APIs without a bridge layer, unlike Flutter, which requires platform channels, adding an extra layer of data translation and potential performance cost.

15:04

๐Ÿ Performance, Maturity, and Future of Cross-Platform Frameworks

The discussion on performance suggests that while both KMP and Flutter compile to native binaries, the lack of a bridge layer in KMP might offer better performance. Maturity is then addressed, with KMP being stable and production-ready, but its UI component, Compose Multiplatform, still in beta or alpha for some platforms. Flutter is acknowledged as stable and widely used. The host speculates on the future, suggesting Google's official support for KMP might indicate a preference over Flutter, despite owning the latter. The company behind KMP, JetBrains, is portrayed as fully committed to its success.

๐Ÿš€ Personal Recommendations and Conclusion

In the concluding paragraph, the host provides personal recommendations based on the analysis. For native Android developers familiar with Kotlin, adopting KMP is recommended due to the learning curve being less steep and the recent Google support. The host believes both technologies will coexist, catering to different developer preferences and project requirements. The video ends with an invitation to a course on building cross-platform apps with KMP and a teaser for more KMP-related content in the future.

Mindmap

Keywords

๐Ÿ’กCross-platform development

Cross-platform development refers to the practice of creating software applications that can run on multiple platforms, such as iOS and Android, from a single code base. In the video, this concept is central as the speaker discusses the use of Kotlin Multiplatform (KMP) and Flutter for developing mobile apps that can run on various operating systems, emphasizing the efficiency and convenience it brings to developers.

๐Ÿ’กKotlin Multiplatform (KMP)

Kotlin Multiplatform is a framework that allows developers to share code across different platforms using Kotlin language. The video highlights KMP as one of the two main cross-platform frameworks being compared, noting its ability to compile shared code into native applications for different platforms, thus potentially offering better performance.

๐Ÿ’กFlutter

Flutter is an open-source UI software development kit created by Google for building natively compiled applications for mobile, web, and desktop platforms from a single codebase. The script contrasts Flutter with KMP, discussing its use of the Dart programming language and its UI rendering approach, which differs slightly from KMP's.

๐Ÿ’กCode sharing

Code sharing is a key feature of cross-platform development frameworks, allowing developers to write code once and deploy it across multiple platforms. The video script discusses how both KMP and Flutter facilitate code sharing, enabling developers to create apps for iOS, Android, desktop, and web from a unified codebase.

๐Ÿ’กCompilation

Compilation in the context of the video refers to the process by which the shared code written in a cross-platform framework is converted into executable code for specific platforms. The script explains how KMP and Flutter handle compilation differently, with KMP compiling to native binaries and Flutter using a bridge layer to communicate with native APIs.

๐Ÿ’กUI rendering

UI rendering is the process of generating the graphical interface of an application. The video discusses the differences in how KMP and Flutter handle UI rendering, with KMP potentially allowing for native UI components through its Compose Multiplatform, while Flutter renders UI components on a canvas across all platforms.

๐Ÿ’กNative APIs

Native APIs are the application programming interfaces provided by the operating system for developers to interact with system functionalities. The script explains how KMP allows direct interaction with native APIs, while Flutter requires a bridge layer, which can impact performance and ease of use when implementing platform-specific logic.

๐Ÿ’กPerformance

Performance in the video refers to how well the applications built with cross-platform frameworks run in terms of speed and resource usage. The script suggests that while both KMP and Flutter compile to native code, the lack of a bridge layer in KMP might offer better theoretical performance compared to Flutter.

๐Ÿ’กMaturity

Maturity in this context refers to the stability and readiness of a technology for production use. The video notes that while KMP is considered stable and production-ready, Compose Multiplatform is still in beta or alpha for some platforms, suggesting it might not be fully mature for all use cases.

๐Ÿ’กFuture assumptions

Future assumptions are the speaker's personal predictions or speculations about the direction in which the cross-platform development market might evolve. The script includes the speaker's thoughts on the potential bright future of KMP, supported by Google, and the coexistence of both KMP and Flutter in the market.

๐Ÿ’กRecommendation

Recommendation in the video is the speaker's personal advice to the viewers on which cross-platform framework to learn or use. The script concludes with the speaker recommending KMP for native Android developers familiar with Kotlin, based on its current support, stability, and potential future growth.

Highlights

Cross-platform development has been a significant aspect of mobile platforms, with native development being equally prevalent.

Two frameworks stand out for building iOS and Android apps from a single code base: KMP (Kotlin Multiplatform) and Flutter.

The video compares KMP and Flutter across various aspects such as code sharing, programming language, compilation, UI rendering, native API communication, performance, maturity, and future predictions.

Both KMP and Flutter allow for code to be shared across iOS, Android, desktop apps, and web platforms.

Kotlin Multiplatform uses Kotlin, while Flutter uses Dart, which some developers find less enjoyable due to its similarities with Java.

KMP compiles shared code into native binaries for each platform, including JVM bytecode for Android and JavaScript for web applications.

Flutter compiles to native code on each platform, but does not compile to JVM bytecode on Android, instead going directly to machine code.

In KMP, UI components can be made native if desired, utilizing the platform-specific components provided by the native development kits.

Flutter does not offer a straightforward way to write native UI components for each platform individually.

KMP uses the expect-actual mechanism to handle platform-specific logic, allowing direct interaction with native APIs.

Flutter requires a bridge layer, known as platform channels, to interact with native APIs, which can impact performance.

Performance-wise, KMP apps are considered pure native apps without the bridge layer that Flutter has, potentially offering better performance.

Kotlin Multiplatform is stable and production-ready, but Compose Multiplatform is still in beta or alpha for some platforms.

Flutter is stable, maintained by Google, and widely used, giving it an advantage in terms of maturity.

Google's official support for Kotlin Multiplatform indicates a promising future for the technology.

The presenter believes that both KMP and Flutter will coexist and cater to different developer needs and project requirements.

For native Android developers familiar with Kotlin, adopting KMP is recommended due to the learning curve and Google's support.

The future of cross-platform development is expected to include a variety of technologies, with each having its place.

The video concludes with a recommendation for developers to learn KMP, especially if they are already working with Kotlin and Android.

Transcripts

play00:00

hey guys and welcome back to a new video

play00:02

crossplatform development has almost

play00:04

always been a thing on mobile platforms

play00:06

just like native has always been a thing

play00:08

but if we take a look at the options we

play00:10

have to build both IOS and Android apps

play00:12

with one single code base and then two

play00:14

Frameworks Stand Out KMP or cotland

play00:17

multiplatform and flut and if you're

play00:19

maybe a native Android developer who now

play00:21

wants to get into crossplatform

play00:22

development or maybe you're also an iOS

play00:24

Developer who's watching here I'm a

play00:26

native Android developer I've been

play00:28

developing Android apps for 5 six years

play00:30

but to be honest crossplatform

play00:31

Frameworks have always been quite

play00:32

tempting for me as well and in this

play00:33

video I will compare the two most

play00:35

popular and in my opinion viable cross

play00:37

platform Frameworks we have for mobile

play00:40

apps so KMP and flatter in a lot of

play00:42

different aspects and categories those

play00:44

categories are on the one hand code

play00:46

sharing so how does it really work that

play00:48

we just put our code at one place and we

play00:50

get two apps out of that then I will

play00:52

compare the programming language each

play00:54

framework uses I will compare how the

play00:56

compilation works so how the shared code

play00:59

is actually compiled and what kind of

play01:01

result we really get out of that

play01:02

compilation for both KMP and flatter

play01:04

apps then I will take a look at how UI

play01:06

rendering works so how do you really

play01:08

draw UI on the screen I will compare how

play01:11

it actually works to communicate with a

play01:13

native apis so how we Implement logic

play01:15

that is really platform specific like

play01:17

showing a notification for example I

play01:18

will also take a look at performance

play01:20

maturity so which framework is safer to

play01:22

use at the moment and then I will make

play01:24

some assumptions about the future so in

play01:26

which direction I think the

play01:27

crossplatform market will go to and last

play01:29

lastly I will just share my own opinion

play01:31

about those Frameworks and give you a

play01:33

specific recommendation which framework

play01:35

you should learn right now so let's talk

play01:37

about code sharing which platforms can

play01:40

we actually develop for with KMP and

play01:42

with flutter and in this regard both

play01:43

platforms are actually quite similar and

play01:45

quite comparable since both these

play01:47

platforms allow us to put our code in

play01:48

one single place and get executables for

play01:51

multiple platforms out of that so

play01:53

specifically those platforms are iOS

play01:55

apps Android apps their desktop apps and

play01:57

even web is supported by both k&p and

play02:00

flutter so in this regard it's a draw

play02:02

here next up talking about the

play02:03

programming language well as the name

play02:05

cotland multiplatform already says it

play02:07

uses cotland surprise so we just have

play02:09

our sheared logic written in pure

play02:11

cocklin Cod which we can then just take

play02:13

and use for all those different

play02:14

platforms I just mentioned on the other

play02:15

hand flusher used the programming

play02:17

language and while I am of course a

play02:18

little bit biased here as a native endro

play02:20

developer who uses cotland all day I can

play02:22

only say the last time I used Dart which

play02:24

is quite some time ago to be honest but

play02:26

it wasn't enjoyable it really reminded

play02:28

me so much of java and there was not a

play02:30

lot of syntactical sugar at least not as

play02:32

we know it from cotlin and that's also

play02:34

the impression I get when I talk to

play02:35

flutter devs who have also tried cotlin

play02:38

coming to the next category and that is

play02:39

compilation so how does the framework or

play02:42

the compiler really take the shared code

play02:44

of the framework and compile it down to

play02:46

something that runs on all these

play02:47

different platforms and while these

play02:48

Frameworks are similar in that regard

play02:50

there is still some differences so if

play02:52

you take a look at cotton multiplatform

play02:53

then it really depends on the target we

play02:55

want to compile an app for that decides

play02:57

how the compilation will work so that

play02:59

means if we have a KMP project that

play03:00

should run on Android then for Android

play03:03

the Cartland compiler will compile the

play03:05

shared Cartland code just to jvm bite

play03:07

code to to Java virtual machine bite

play03:09

code that is the primary format Android

play03:12

apps are just compiled to which Android

play03:14

understands so that is native for

play03:15

Android on iOS fiber we don't have a jvm

play03:18

since that just works with the native

play03:20

binaries so just a bunch of zeros and

play03:21

ones that represents some kind of

play03:23

instructions for the CPU of iOS devices

play03:26

but here again the coton compiler will

play03:28

take the shared code and compile it to

play03:29

the those native binaries that run on

play03:31

iOS so it's also a native IOS app and

play03:33

the same also comes for desktop app so

play03:35

here we have the option to actually

play03:36

compile it down to jvm bite code since

play03:38

we have the jvm available on desktop but

play03:40

it's also reasonable to compile it down

play03:42

to native code which can also be run on

play03:44

a desktop environment lastly if we take

play03:45

a look at web applications then the

play03:47

cotton multiplatform code will really

play03:48

just compile down to JavaScript the

play03:51

programming language that will used

play03:53

everywhere in web so in regards to coton

play03:54

multiplatform all those platforms really

play03:57

get native applications out of our

play03:59

shared cotton code that's very cool of

play04:00

course since native usually also means a

play04:02

better performance than non-native if we

play04:04

take a look at flutter on the other hand

play04:06

we also get native apps on all these

play04:08

different platforms that's something

play04:10

many people don't know I feel like

play04:11

because you always hear okay KMP apps

play04:13

are actually native while flutter apps

play04:15

are not and I will also share in a

play04:16

moment why that is actually the case or

play04:19

why people say this but technically

play04:20

flutter apps compile to native code on

play04:22

each platform as well the only

play04:24

difference for flutter is that it does

play04:25

not compile to jvm bite code on Android

play04:28

but rather to machine code directly but

play04:30

that can also run on Android devices

play04:31

let's next compare the UI rendering so

play04:34

how do we achieve that we put our UI at

play04:37

one central place and it looks the same

play04:39

on all these different platforms these

play04:40

points are similar again but there are

play04:42

still some slight differences so on

play04:44

carton multiplatform all UI widget so

play04:46

all composes if you're using compos

play04:48

multiplatform that is the Assumption I

play04:50

have to make here because otherwise you

play04:51

can't share UI code in cartet

play04:53

multiplatform but if you're using compos

play04:54

multiplatform then the entire UI so your

play04:57

entire jetpack compos code in the

play04:59

multiplat project will be drawn from

play05:01

scratch so you can think of this as just

play05:03

having a native canvas component on iOS

play05:06

side and they compos multiplatform

play05:08

framework will then figure out okay this

play05:09

is our compost code and this is how it

play05:11

needs to translate into canvas

play05:13

coordinates so we just draw that on the

play05:15

native canvas and iOS so the UI

play05:17

components we Implement in composed

play05:18

multiplatform are not technically native

play05:21

components but you have the option to

play05:24

make them native components that is very

play05:26

unique to carton multiplatform so if we

play05:28

want to use the platform specific

play05:30

components that the in this case Apple

play05:33

developer kit provides here in Swift UI

play05:35

in that case we can do that in C

play05:37

multiplatform since it allows us to

play05:38

write platform specific code natively

play05:40

for every single platform so if we

play05:42

really want those native Apple

play05:43

components then we just need to

play05:45

implement those in Native Apple code in

play05:47

Swift therefore with flutter on the

play05:49

other hand drawing the UI works very

play05:51

similar than on compos multiplatform

play05:53

that it will just draw everything uh

play05:56

that we Define in flutter on a canvas on

play05:57

all platforms that's fine for sharing

play05:59

but with flutter we don't have the

play06:01

option to actually write native UI

play06:03

components for every single platform

play06:04

individually at least not in an as

play06:06

straightforward way as we have with KMP

play06:08

coming to the next category and that is

play06:10

how do we communicate with Native apis

play06:13

so while we can of course share a lot of

play06:15

code between all platforms with these

play06:17

two Frameworks there will always be

play06:19

scenarios where specific platforms need

play06:21

specific logic so imagine you're

play06:23

building a mobile and a desktop app on

play06:25

desktop apps the file system even on

play06:27

Windows environments works completely

play06:29

differently on Mac OS environments and

play06:31

that is completely differently how it

play06:32

works on Android environments if we now

play06:34

want to share some logic regarding the

play06:35

file system then we somehow need to tell

play06:38

each platform how it works with the file

play06:41

system specifically from that platform

play06:43

and in KMP that works with the expect

play06:45

actual mechanism so in our common code

play06:47

we can just expect a specific type of

play06:50

class and then we have actual

play06:52

implementations of that class for every

play06:54

single platform individually so we say

play06:56

okay on desktop interacting with files

play06:58

works like this this is the file path

play06:59

for desktop this is the file path for

play07:01

mobile oh on Android we actually also

play07:02

need permissions these kinds of things

play07:04

we can uh Implement very individually

play07:06

for every single platform on KMP and the

play07:08

big Advantage here with KMP is that we

play07:10

can directly interact with the native

play07:12

apis so the native apis would really be

play07:14

those apis the platform itself provides

play07:17

so if we think of showing a notification

play07:19

for example then there is already a

play07:22

system API in Android that provides

play07:24

functionality for us that we can call in

play07:26

order to see a notification or Android

play07:28

device showing a notification on iOS

play07:30

Works differently but there's also a

play07:31

system API that Apple provides to us and

play07:34

with KMP that is really unique about it

play07:36

we can directly talk to these two system

play07:38

apis without any Bridge layer that does

play07:41

the translation from or cotlin code to

play07:43

the native code or to to the to the

play07:44

native apis on flutter that works

play07:47

differently because flutter can't

play07:49

directly call those native apis while

play07:51

flutter can of course somehow interact

play07:53

with Native apis otherwise this would be

play07:55

quite a problem there is still a bridge

play07:57

layer necessary in flatter Earth so

play07:58

these are called platform channels

play08:00

actually how how that works so the dart

play08:03

code will just use such a platform

play08:05

channel so just a stream of data that

play08:07

can be used to exchange bits and btes

play08:10

and this platform Channel then leads to

play08:11

the native apis but as you can see there

play08:13

is a bridge layer so some kind of

play08:15

channel that needs to interpret the

play08:17

flatter code and translate that to calls

play08:20

to the native apis and for the common

play08:22

functionality you might want to share I

play08:23

don't know camera access recording video

play08:25

showing notifications flatter has all

play08:27

kinds of plugins also from the Community

play08:30

which you can just use in your shared

play08:32

code and those plugins were then written

play08:33

in native code for every single platform

play08:35

so you can use these out of the box

play08:37

however with flutter you really don't

play08:38

get around having this platform channel

play08:40

so this intermediate step kind of which

play08:42

is of course just an extra layer data

play08:44

has to pass Which is less performant

play08:46

than if we just call the native apis

play08:48

directly like we can do with KMP next

play08:51

category is performance which framework

play08:53

actually builds the better performing

play08:55

apps and I have to say I will really

play08:56

focus on the let's call it theoretical

play08:59

per performance because in order to

play09:00

truly compare the performance between

play09:02

KMP and flutter we would need some kind

play09:04

of real studies that compare the

play09:06

performance of flutter and KP apps where

play09:09

the apps exactly the same in different

play09:11

categories of apps and so on and I did

play09:13

not find such studies so all I can say

play09:15

here is that KMP apps as I said are pure

play09:18

native apps just like flatter apps but

play09:20

there is not this bridge layer that I

play09:21

talked about so Cartland multiplatform

play09:23

apps actually also share the same memory

play09:25

space and call stack as the platform

play09:27

that it's running on that is not the on

play09:29

flutter apps so on the one hand as I

play09:31

said on flutter apps we have this bridge

play09:32

layer which does the translation from

play09:34

the darkart code to the native code or

play09:36

to the native API calls and flutter apps

play09:38

are also running in their own kind of

play09:40

isolated environment on the dart VM Dart

play09:42

virtual machine so that means they also

play09:44

don't share the same memory space and

play09:46

call stack as the platform that's

play09:47

running on and this does not make

play09:49

flutter apps true native apps so while

play09:51

they compile to Native binaries

play09:53

technically they are still not really

play09:55

treated as native apps and that's really

play09:57

what people mean when they say KMP

play09:59

brings native apps well flatter does not

play10:01

so let's talk about maturity next

play10:03

according to Jet brains carton

play10:04

multiplatform is stable and if something

play10:06

is stable then it's also considered

play10:08

production ready that's also my

play10:10

experience when I've been using that

play10:11

it's quite stable if we just use Carton

play10:13

multiplatform and I rarely run into any

play10:15

weird issues with it however we need to

play10:17

take a look at compos multiplatform

play10:18

individually because compos

play10:20

multiplatform is really just some kind

play10:21

of add-on to C multiplatform that allows

play10:24

us to also share UI code between all

play10:25

those different platforms and composed

play10:27

multiplatform is not officially St say

play10:29

that it is for Android since jet compos

play10:31

is a technology that was primarily made

play10:33

for Android but for the iOS side for

play10:35

example it is in beta currently and also

play10:37

for web platforms it's even an alpha so

play10:39

compos quity platform still has a path

play10:41

in front of it and to be honest if I

play10:43

would have to seriously build a

play10:44

production ready app with a

play10:46

crossplatform framework then at this

play10:47

point I wouldn't feel confident with

play10:49

using compos multiplatform yet so I

play10:51

think right now is the perfect time to

play10:52

try it out to use it in your hobby

play10:54

projects to experiment with it but I'd

play10:56

still be careful with production apps

play10:58

since even if it might look very cool on

play10:59

the first glance the dangers of such

play11:01

unstable Technologies are always that

play11:03

they might lead to issues you don't even

play11:05

think of at first but at a much later

play11:07

time so imagine you already built maybe

play11:09

a 10 15 screen app with composed

play11:11

multiplatform everything was cool until

play11:13

then but then you start to experience

play11:15

weird performance issues or whatever and

play11:17

at that point it's too late if you then

play11:18

want to switch the technology you need

play11:19

to rewrite everything or at least the UI

play11:21

layer in C multiplatform so that's why

play11:24

thinking about this from the very

play11:25

beginning on really matters here so this

play11:27

is honestly a point that I have to give

play11:28

to flatter at this point since flatter

play11:30

has been around for quite some time it

play11:32

is stable it is maintained by Google and

play11:34

also broadly used and applied for lots

play11:36

of different apps but if we really

play11:38

compare cotland multiplatform so without

play11:40

compose with flutter here then I think

play11:43

these are even and getting to the last

play11:44

category before I want to share my

play11:46

personal opinion and recommendation for

play11:48

you let's talk about future

play11:50

unfortunately I forgot my crystal ball

play11:53

here so everything I say here are just

play11:55

my personal assumptions of course but

play11:57

maybe you noticed that Google actually

play11:59

announced during Google's yly event

play12:01

Google IO that cotland multiplatform is

play12:04

now an officially supported technology

play12:06

by Google and I think this has been a

play12:09

marker for a very bright future of

play12:11

carton multiplatform and you might not

play12:12

think okay but flutter is actually owned

play12:14

by Google and KMP is only supported by

play12:17

Google how does it make that better that

play12:19

Google supports coton multiplatform than

play12:21

that it ouns flutter I personally think

play12:24

the fact that Google actually decides to

play12:27

officially support a technology don't

play12:29

own because cin multiplatform is owned

play12:32

by jet brains but still Google decided

play12:34

to officially support it even though

play12:35

they have their own technology that does

play12:37

exactly the same but that actually

play12:38

solves the same type of problem at least

play12:40

the fact that they decided to do so

play12:42

could show that Google Sees more future

play12:44

in C multiplatform than in fletter

play12:46

because why else would they support a

play12:48

technology they don't even own and this

play12:50

of course just conspiracy time I could

play12:52

be very wrong with that assumption but I

play12:54

still find that very interesting that's

play12:55

like Samsung buying Apple stocks why

play12:58

would they do that if they have their

play12:59

own stocks and one more reason why I

play13:01

really believe that c multiplatform will

play13:02

have a very bright future is that the

play13:05

company behind it jet brains really sees

play13:06

it as their baby if you follow them on

play13:08

social media and how they promote it you

play13:10

really notice that they they do

play13:12

everything in their power to make coton

play13:14

multiplatform succeed and a viable

play13:15

technology however if we take a look at

play13:17

flatter at the present moment then yes

play13:19

that is officially maintained by Google

play13:21

it also belongs to Google it's a Google

play13:23

product but the past has shown that

play13:24

Google is actually not very afraid of

play13:26

suddenly stopping support for products

play13:28

they are own morning and I'm not saying

play13:30

that this will happen to flatter soon no

play13:32

I don't think that but I am saying that

play13:34

I would trust Google much more to

play13:36

abandon flutter then I would trust jet

play13:38

brains to abandon KMP because I don't

play13:40

see flutter as Google's baby while I see

play13:43

KMP as jet brain's baby and Indian

play13:44

Google is just such a giant company that

play13:47

if flutter would be gun Google would be

play13:49

at exactly the same position as it is

play13:51

right now well I think if jet brains

play13:53

would suddenly lose KMP for whatever

play13:55

reason that would really hurt their

play13:57

reputation of course jet Brain still has

play13:59

some other awesome products like all

play14:00

those cool idees but I see carton

play14:02

multiplatform as one of jet print's cool

play14:04

products so what does now my personal

play14:06

opinion what do I recommend you to do

play14:09

right now or if you want to learn

play14:10

crossplatform which technology should

play14:12

you really pick and my opinion here is

play14:13

really clear if you are a native Android

play14:16

developer and you know cotland then

play14:17

jumping into KMP is just a no-brainer

play14:19

from my side because you really already

play14:21

know most of what you need for KMP

play14:23

because in the end you know the

play14:24

programming language you know many

play14:26

Concepts that are used in Cut

play14:28

multiplatform project especially with

play14:30

the just announced Google support which

play14:32

will add all those jetpack libraries we

play14:34

already know from Android also for KMP

play14:36

so all that will not be new to you the

play14:37

only thing you really need to learn is

play14:39

how you implement patform specific code

play14:41

so the learning curve is not steep at

play14:43

all however that also doesn't mean that

play14:44

I think flatter will go anywhere anytime

play14:46

soon I personally think both

play14:48

technologies will just coexist I

play14:50

personally am also convinced that there

play14:52

won't be just that one single way in

play14:54

future of building mobile apps people

play14:55

have been saying that for decades that

play14:58

specific technology will take over all

play15:00

other jobs will be lost I don't believe

play15:02

in that I think Native will still exist

play15:04

there will be native iOS developers

play15:05

native Android developers there will be

play15:07

crossplatform developers with flutter

play15:08

there will be crossplatform developers

play15:10

with KMP and all those will be viable

play15:12

technologies that are viable for

play15:14

specific set of people specific set of

play15:16

goals and specific set of requirements

play15:18

and especially if we also take a look at

play15:20

the iOS side if we take a look at Native

play15:22

iOS developers I have the feeling that

play15:25

they often just live completely in their

play15:26

own world and that Technologies like C

play15:28

multiplatform completely go past them so

play15:31

if you want a general recommendation I

play15:32

would say go KMP if you are already

play15:34

building flatter apps and you enjoy that

play15:36

then this is not a reason to switch from

play15:38

that just because KMP is Now supported

play15:40

by Google I don't believe that this is

play15:41

the end of flutter however I still

play15:43

believe that KMP has a very bright

play15:44

future and that's also why you will see

play15:47

much more CET multiplatform and composed

play15:49

multiplatform tutorials in future on my

play15:51

channel and if you want to learn how you

play15:52

can build a full crossplatform app in

play15:54

Cotton multiplatform with a native UI

play15:57

check my course down below other than

play15:58

that thanks for watching this video I

play15:59

will see you back in the next one have

play16:01

an amazing rest of your week bye-bye

Rate This
โ˜…
โ˜…
โ˜…
โ˜…
โ˜…

5.0 / 5 (0 votes)

Related Tags
Cross-PlatformApp DevelopmentKotlin MultiplatformFlutterMobile AppsAndroidiOSCode SharingUI RenderingPerformanceMaturityFuture TrendsDeveloper GuideTechnology ReviewProgramming LanguagesNative AppsKMP vs FlutterTech TutorialGoogle SupportJetBrainsAndroid DeveloperiOS Developer