I'm testing Kotlin `2.3.0-Beta1` and trying to `@J...
# javascript
r
I'm testing Kotlin
2.3.0-Beta1
and trying to
@JsExport
a class with suspending method. I'm getting
Declaration of such kind (suspend function) cannot be exported to JavaScript.
error. I thought it had been fixed as https://youtrack.jetbrains.com/projects/KT/issues/KT-56281. Was I wrong?
1
h
Did you enable the language feature: JsAllowExportingSuspendFunctions
Looking at the source code it’s needed
r
Thank you. Indeed I need to set language version to 2.4
Copy code
compilerOptions {
            languageVersion.set(KotlinVersion.KOTLIN_2_4)
        }
a
Does 2.3.0-Beta1 export suspending functions as Promises?
👌 1