stevdza-san / KotlinBootstrap

Use the official Bootstrap UI components with Kotlin and Compose HTML, to build a frontend on the web.
167 stars 9 forks source link

Doesnt support kotlin 1.9.22 #13

Closed timkabot closed 2 weeks ago

timkabot commented 3 months ago

When upgrading versions higher than in projects the error occurs

For example: Function 'BSNavBar' can not be called: No function found for symbol 'com.stevdza.san.kotlinbs.components

stevdza-san commented 3 months ago

Hey @timkabot I've just pushed a new release with the Kotlin version updated to 1.9.22. Check it out and let me know. :)

javad0470 commented 3 months ago

yeah that's my error as well IrLinkageError : "Function 'BSCarousel' can not be called: No function found for symbol " it's not support kotlin 1.9.22

stevdza-san commented 3 months ago

@javad0470 Have you tried updating this library's version to v0.1.1?

javad0470 commented 3 months ago

yes i do

stevdza-san commented 3 months ago

@javad0470 Could you paste your libs/version catalog dependency versions here?

javad0470 commented 3 months ago

[versions] jetbrains-compose = "1.6.0" kobweb = "0.17.0" kotlin = "1.9.22"

implementation("com.github.stevdza-san:KotlinBootstrap:0.1.1")

stevdza-san commented 3 months ago

@javad0470 Try using these instead:

jetbrains-compose = "1.5.12" kobweb = "0.16.1" kotlin = "1.9.22"

Check the compatibility file inside the kobweb library as well. But right now those versions work pretty good for me: https://github.com/varabyte/kobweb/blob/main/COMPATIBILITY.md

EugeneAksyonov commented 3 months ago

@stevdza-san I do confirm that 0.16.1+ | 1.5.12 | 1.9.22 works! But I eager to see support under 0.17.0+ | 1.6.0 | 1.9.22 where runtime fails on call of any BS object. I tested BSSpinner() and getting this error: { "message": "Function 'BSSpinner' can not be called: No function found for symbol 'com.stevdza.san.kotlinbs.components/BSSpinner|BSSpinner(com.varabyte.kobweb.compose.ui.Modifier?;com.stevdza.san.kotlinbs.models.SpinnerStyle?;com.stevdza.san.kotlinbs.models.SpinnerVariant?;androidx.compose.runtime.Composer?;kotlin.Int;kotlin.Int){}[0]'", "name": "IrLinkageError" }

The issue, perhaps, related to support of Compose 1.6.0+ version by kobweb (@bitspittle ). When I call Compose Resources (stringResource(...) supported since 1.6.0+) I do get exception in runtime as follow { "message": "CompositionLocal LocalDensity not present", "name": "IllegalStateException" } is it incompatible Composables on the same composition issue? If there are any hot-fixes I can quickly test it, just in case.

EugeneAksyonov commented 3 months ago

I do believe I described two different issues, Bootstrap related one does not depend on Compose Resources (compose.components.resources) library that causes stringResource(...) exception. It can be incompatible in co-using.

ZoranUTF8 commented 3 months ago

I can also confirm that the following versions are compatible and function correctly:

jetbrains-compose = "1.5.12" kobweb = "0.16.1" kotlin = "1.9.22"

Screenshot 2024-03-21 at 12 57 36
AmadeAli1 commented 1 month ago

I can also confirm that the following versions are compatible and function correctly:

jetbrains-compose = "1.5.12" kobweb = "0.16.1" kotlin = "1.9.22"

Screenshot 2024-03-21 at 12 57 36

When add this code??

stevdza-san commented 2 weeks ago

The new release is updated with:

Update to Kotlin 1.9.23
Update to Kobweb 0.18.0
Update to Compose 1.6.2