Skip to content

feat(KMP-1): add Compose Multiplatform and library-kmp-module convention plugin#171

Open
js-jasinski wants to merge 1 commit into
matejdro:mainfrom
js-jasinski:feat/KMP-1-compose-multiplatform
Open

feat(KMP-1): add Compose Multiplatform and library-kmp-module convention plugin#171
js-jasinski wants to merge 1 commit into
matejdro:mainfrom
js-jasinski:feat/KMP-1-compose-multiplatform

Conversation

@js-jasinski

Copy link
Copy Markdown

Introduces a library-kmp-module convention plugin in buildSrc so modules can target Android and iOS with Compose Multiplatform. Uses the AGP com.android.kotlin.multiplatform.library plugin (avoids the kotlin.android <-> kotlin.multiplatform conflict) and gates iOS targets to macOS.

…ugin

Introduces a `library-kmp-module` convention plugin in buildSrc so modules can
target Android and iOS with Compose Multiplatform. Uses the AGP
`com.android.kotlin.multiplatform.library` plugin (avoids the
kotlin.android <-> kotlin.multiplatform conflict) and gates iOS targets to macOS.
@js-jasinski js-jasinski changed the title KMP-1: add Compose Multiplatform and library-kmp-module convention plugin (feat): KMP-1: add Compose Multiplatform and library-kmp-module convention plugin Jul 1, 2026
@js-jasinski js-jasinski changed the title (feat): KMP-1: add Compose Multiplatform and library-kmp-module convention plugin feat(KMP-1): add Compose Multiplatform and library-kmp-module convention plugin Jul 1, 2026
minSdk = 30
}

if (isMac) {

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

iOS targets should always be created, even if opened on a non-mac machine.

Otherwise, we will get Dispatchers.IO conflicts: Kotlin/kotlinx.coroutines#4568

See coredevices/mobileapp#47, we had that same issue in the Core app

id("org.jetbrains.kotlin.plugin.compose")
id("org.jetbrains.compose")

id("checks")

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file currently duplicates a lot of things from the all-modules-commons. Can we try reusing it instead, so android and kmp modules have a common base without duplication?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants