Skip to content

Eagerly create jvm target for KMP #1377

@Goooler

Description

@Goooler

Please don't call jvm(). Because this method declares a jvm target in KMP project. And users should do that explicitly.
More over, they can specify a custom name for their jvm target.
The correct API is to lazily iterate over targets collection. And check for KotlinJvmTarget instance.

kmpExtension.targets.configureEach { target ->
   if (target is KotlinJvmTarget) // do configuration here
}

Originally posted by @antohaby in #1280 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions