How to Migrate an Android Project to Kotlin Multiplatform (KMP)

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ต.ค. 2024

ความคิดเห็น • 67

  • @khanzadakashif8248
    @khanzadakashif8248 10 หลายเดือนก่อน +33

    It was a good tutorial, but it would be better if you now create one in which you migrate this project to share the UI as well with compose multiplatform.

  • @OlegsPliska
    @OlegsPliska 2 หลายเดือนก่อน +3

    If you don't see option of creating a KMP module, you need to turn on experimental settings:
    In Android Studio settings, turn on the Enable experimental Multiplatform IDE features option in the Advanced Settings section.

  • @jamesdavenavor6247
    @jamesdavenavor6247 10 หลายเดือนก่อน +1

    Thanks a lot Philipp
    I was already trying to figure out how to do it but you just went and gave an answer

  • @vikashparajuli
    @vikashparajuli 10 หลายเดือนก่อน +2

    Cheers for the tutorial.
    In the real project, there will be lots of work on the migration. Most of the libraries (written in java) that we use on the native android app doesn't work on KMP. This needs to be replaced with the KMP support libraries.

  • @Wallenlaguinee
    @Wallenlaguinee 10 หลายเดือนก่อน +1

    Wow, Flutter dependency configuration is so much easier. "flutter pub get [your desired package]".
    But thanks for an informative tutorial as usual!

  • @atglira
    @atglira 5 หลายเดือนก่อน

    My hero! thank you very much! amazing job Mr. Lackner

  • @mohanaggarwal4058
    @mohanaggarwal4058 9 หลายเดือนก่อน +1

    Please make a tutorial to make desktop app from existing Android app project

  • @genzlearnstocode
    @genzlearnstocode 10 หลายเดือนก่อน +1

    please make a tutorial video about how to configure dekstop, ios android KMM.

  • @MobileMastersAndroidiOS
    @MobileMastersAndroidiOS 10 หลายเดือนก่อน

    Great job Philipp!

  • @QuangNgôHuy
    @QuangNgôHuy 10 หลายเดือนก่อน +2

    Hi Philipp, I have a question and hope you will answer it for me.
    We interact between view and viewmodel using state variable and onEvent function written in viewmodel. Because all states are written into State data class (Ex: HomeState), when there is an event such as click the button or enter text in textfield, onEvent function will be called. This will result in the state variable being assigned a new value, and all views related to this state variable in the Screen will be recomposed. This is something we do not want to happen. Can you give me some solution to fix this?
    Thank you so much... ❤

  • @abacaabaca8131
    @abacaabaca8131 10 หลายเดือนก่อน +1

    I must say i never understand gradle but currently i am learning libgdx because i was suprised kotlin can be used and run the .apk on android. And its working. Maybe later i will try this (compile into apple).

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +1

      Is that a 2d engine?

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +2

      Gradle sucks and it’s a required pain point for android dev

    • @footballCartoon91
      @footballCartoon91 10 หลายเดือนก่อน

      @@ChrisAthanas i was able to follow a tutorial from gamefromscratch youtube channel and render a 3d model with animation in my android phone. But it uses JSON library if not mistaken to parse the .g3db (the binary format) of the model's object file . If you want it to parse its respective text format which is .g3dj it can do it as well. But currently, i want to figure out how to configure the camera for controlling the model's movement.

  • @SamandarSdk
    @SamandarSdk 10 หลายเดือนก่อน +1

    Nice video Philipp. Have u tried Fleet ide?

  • @ranjanrukhaya3025
    @ranjanrukhaya3025 10 หลายเดือนก่อน

    Great work @philipp lackner Just wandering how we can do it for android library. Can we have a tutorial on this, that would be really helpful. Thx

  • @asifmehmood9307
    @asifmehmood9307 10 หลายเดือนก่อน +2

    Great job @philipp lackner I have one question from kotlin DSL or version catalog which one is better than for handling dependencies?

    • @sudarshanbhatt9435
      @sudarshanbhatt9435 10 หลายเดือนก่อน

      both are independent things. but you can use version catalog, its pretty handy and easy to use

  • @mahmoudalkateb2008
    @mahmoudalkateb2008 10 หลายเดือนก่อน

    LETS GOOOO 🎉

  • @swish6143
    @swish6143 8 หลายเดือนก่อน +2

    I don't get the sharedModule option in 4:10 although I have the KMP Plugin installed. I can also create a new KMP Project.

    • @jeremymacnicol6023
      @jeremymacnicol6023 7 หลายเดือนก่อน

      I'm having the same problem. I'm using Android Studio Hedgehog if that means anything.
      Ultimately, I copied the "shared" module from the second project and pasted into the original. Hopefully that works.

    • @marcelbreas3544
      @marcelbreas3544 7 หลายเดือนก่อน +7

      That’s because of the earlier version of the KMP plugin used in the video. I believe this feature was later marked as experimental and in doing so was removed from being shown. You can enable it by going into Android Studio settings and search for ‘kotlin’ under Advanded Settings. A search result ‘Enable experimental Multiplatform IDE features’ should pop up. Enable it, hit apply and restart Android Studio. The option should now show up when you try to create a new module.

    • @Desuzedart
      @Desuzedart 7 หลายเดือนก่อน

      @@marcelbreas3544 thank u guys, i faced the same problem. Ur workaround resolved the problem! Best wishes

    • @Kmg403
      @Kmg403 6 หลายเดือนก่อน

      @@marcelbreas3544 thank you, this worked.

    • @superkobke
      @superkobke 4 หลายเดือนก่อน

      @@marcelbreas3544 Thanks, making the video is easy but answering questions, apparently not

  • @tutrieu3250
    @tutrieu3250 10 หลายเดือนก่อน +1

    I have a question.if I use window.Can I run KMP without plugin xcode ios right?😢😢

  • @JacobFerrero
    @JacobFerrero 10 หลายเดือนก่อน +1

    Hey Philipp, do you have any tutorials on how to dynammically load KMP modules, specifically for Web projects? I want to reduce the size of my initial download every visitor needs to download.

  • @soc3xp
    @soc3xp 9 หลายเดือนก่อน

    KMM 🎉

  • @theren8311
    @theren8311 6 หลายเดือนก่อน

    IDK man, I appreciate the video, but it's no different from the docs, and you easily consume the docs better. Or maybe it's just me, because if I watched this first I would have to rewatch scenes over because of all the zipping around. But looking at the comments, I guess everyone has their preference. I was hoping watching this I would get something more.

  • @arozendojr
    @arozendojr 10 หลายเดือนก่อน +1

    Can you make GitHub available, commit before and after migration, please

  • @nomejodas2978
    @nomejodas2978 10 หลายเดือนก่อน +2

    Philipp, do you think it would be wise to do all the Domain and Data layer using KMM and the presentation later using Flutter?

  • @daniyar2718
    @daniyar2718 4 หลายเดือนก่อน

    thanks for this video

  • @moonlightstudio
    @moonlightstudio 8 หลายเดือนก่อน

    I ask for a tutorial on how to migrate the JVM library to Kotlin multiplatfrom?

  • @abdelrahmankhaled7575
    @abdelrahmankhaled7575 10 หลายเดือนก่อน +2

    Can we use the new editor Fleet IDE to write the ios code on a windows pc instead of mac xCode IDE ?

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +2

      Likely true but the standard for android will be android studio for next couple years

    • @arsildo
      @arsildo 10 หลายเดือนก่อน

      No to write and test ios apps you need a mac

  • @gofudgeyourselves9024
    @gofudgeyourselves9024 10 หลายเดือนก่อน

    Also you should make part two of this video on add KMP code to existing android projectto run it on iOS. Just a simple hello world would do.

  • @zaidkamil
    @zaidkamil 10 หลายเดือนก่อน +2

    I am on windows PC, i cant use the IOS modules, and it gives a ton of error. What about it

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +1

      Sorry you need a Mac for the iOS side

    • @RexTorres
      @RexTorres 10 หลายเดือนก่อน +1

      You need to have XCode which is only available on macOS, because... Apple.

  • @argahutama
    @argahutama 10 หลายเดือนก่อน +3

    Hi Philipp,
    Can we modularize KMP app? For instance, separate the layer of data-domain-presentation?

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +2

      Yes not a problem for kmp

    • @arsildo
      @arsildo 10 หลายเดือนก่อน

      I have been banging my head over this, while you can you have to manage ios frameworks which so far i have had no luck or the skill to perform. At first I went in with the idea of creating my featureA module and have for example featureA ui in Compose and featureA with swiftUi in ios and the common code between them and then import that featureA to the main module, but no that doesn't work or i haven't managed to do it yet, or don't even know if it is possible at this point

    • @arsildo
      @arsildo 10 หลายเดือนก่อน +2

      a video on this would be great @PhilippLackner

    • @moldovanpeter5123
      @moldovanpeter5123 10 หลายเดือนก่อน

      There is the KMM course from Philipp where he covers this in details. I am suggesting also to read some articles and case studies to broaden your knowledge 😊. Ex. Touchlab.

  • @unknownbiri
    @unknownbiri 10 หลายเดือนก่อน +6

    Hey. I did code android back then. Then i learned a little web development. But now i can say that coding android was much more fun to me. What do you think is it worth learning android dev in 2024 ? Is there demand ?

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +4

      With KMP it will be the way to produce cross platform apps

    • @unknownbiri
      @unknownbiri 10 หลายเดือนก่อน +2

      @@ChrisAthanas hmm, that is great reason to come back. I'll think about it

  • @kesavguru415
    @kesavguru415 10 หลายเดือนก่อน

    Nice live Philipp 🎉😊

  • @mohamed-tyb
    @mohamed-tyb 10 หลายเดือนก่อน +1

    is kmm or kmp is best choise

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +3

      KMP is the new name of KMM

  • @AsifShaikh-d4e
    @AsifShaikh-d4e 9 หลายเดือนก่อน

    Getting 'Failed building KotlinMPPGradleModel" error how to solved it.

  • @samer616
    @samer616 10 หลายเดือนก่อน

    Hey Philipp, does the premium course use a multi modular architecture?
    I have a multi modular project using CLEAN on Android and would like to migrate to use KMP for the new iOS project.

  • @arozendojr
    @arozendojr 10 หลายเดือนก่อน

    I got an old MacBook that runs iOS simulator, is it possible to run xcode on my M1 and run iOS app on the old MacBook?

  • @uop6238
    @uop6238 10 หลายเดือนก่อน

    I remember Kotlin Multiplatform "mobile" is deprecated 🧐

  • @archit7606
    @archit7606 10 หลายเดือนก่อน

    Hi. Is your KMM course 69.00£ or 69,00£? Please clarify.

    • @ahmadab9666
      @ahmadab9666 10 หลายเดือนก่อน +3

      ??

    • @archit7606
      @archit7606 10 หลายเดือนก่อน

      @@ahmadab9666 pl-coding Website he has his courses. There I saw the price for KMM to be £69,00. That's why I asked whether it is £69 or £69,00.

    • @PhilippLackner
      @PhilippLackner  10 หลายเดือนก่อน +1

      69 euros. How the decimal is interpreted differs per region

  • @pablovaldes6022
    @pablovaldes6022 10 หลายเดือนก่อน

    I would rather just git clone and existing template and transfer my Android code to it

  • @rahulraj94391
    @rahulraj94391 10 หลายเดือนก่อน

    1st

  • @gofudgeyourselves9024
    @gofudgeyourselves9024 10 หลายเดือนก่อน +1

    Anyone getting this error clang: error: no such file or directory: ' -framework shared'

  • @MASSILOULDMOHAND
    @MASSILOULDMOHAND 5 หลายเดือนก่อน

    i have error "org.gradle.api.plugins.UnknownPluginException: Plugin [id: 'com.android.application', version: '8.1.2', apply: false] was not found in any of the following sources:
    "

  • @topGfanboy
    @topGfanboy 10 หลายเดือนก่อน

    😂😂😂... Google Dart has already started interop with JVM... RIP kotlin soon..

  • @mohamed-tyb
    @mohamed-tyb 10 หลายเดือนก่อน +1

    is kmm or kmp is best choise

    • @ChrisAthanas
      @ChrisAthanas 10 หลายเดือนก่อน +2

      KMP is the new name for KMM