-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow enabling compose compiler per target in multiplatform module #4209
Comments
Will this solution work for you? #3722 |
Thanks, It definitely helps a lot! It likely will resolve all the practical issues I have for now. Just curious though, what is stopping us from implementing control at an even finer level of granularity such as per source set or per gradle configuration? |
Not sure that configuring it per source set is possible at all. The source sets can't be compiled independetly. All relevant source sets get "combined" to compile for a particular target, and if a target declares to apply the Compose plugin, it means it's applied to all code (involved source sets). And as for gradle configurations, I'm not sure I understand how it can affect the logic to apply or not apply the plugin. |
I realize I misunderstood some terminology. You mentioned in your PR you can have
Which you referred to as multiple "targets". I thought these were called source sets, but I think I was wrong here. This can be closed I think? Thank you. |
Yes, those are 2 jvm targets with different names. Sure, let's close it. |
Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks. |
Consider a project with a single multiplatform module with a js target for frontend and a jvm target for backend. This module might want to only enable the compose gradle plugin, compose compiler, and compose dependencies for the JS target and completely leave out compose for the jvm target.
This is discussed in #1568. But it seems that issue is being treated as a question and not an enhancement proposal. So here I am making the proposal that the Compose Multiplatform Gradle Plugin allows developers to toggle compose per Kotlin Multiplatform target within a single module.
The text was updated successfully, but these errors were encountered: