https://kotlinlang.org
Join Slack
Hi all, How can I use WebView for Compose MultiPlatform Desktop ?
b

Beta Tech

over 2 years ago
Hi all, How can I use WebView for Compose MultiPlatform Desktop ?
b
n
+2
  • 4
  • 3
  • 1778
Can compose infer stability of a `sealed` class ? ```sealed class MyClass { object A : MyClass()...
r

ritesh

almost 4 years ago
Can compose infer stability of a
sealed
class ?
sealed class MyClass {
  object A :  MyClass()
  data class SomeClass(val value:String): MyClass()
}
r
g
+2
  • 4
  • 28
  • 1778
Are there hot reload in android native kotlin for android studio 4.2, if there aren't so when we get...
o

onirutlA

over 4 years ago
Are there hot reload in android native kotlin for android studio 4.2, if there aren't so when we get hot reload?
o
c
  • 2
  • 2
  • 1777
Hey ! I want to ask people around if `runCatching` is in use in any of your Kotlin (or Android) pro...
n

Nino

almost 3 years ago
Hey ! I want to ask people around if
runCatching
is in use in any of your Kotlin (or Android) projects ? I feel my team is abusing it and I'm trying to understand if there's any "pros" about using it in any coroutine-based codebase. My team just adopted this convention and I'm at loss of words. (Examples in thread for anyone interested)
n
j
+6
  • 8
  • 107
  • 1769
is there is a multiplatform library for URL Encoding with parameter?
i

itnoles

almost 3 years ago
is there is a multiplatform library for URL Encoding with parameter?
➕ 1
i
k
+2
  • 4
  • 4
  • 1767
Hello, I’m trying to use Micrometer Tracing in Spring Boot 3.0 with Kotlin, but I think it’s not wor...
p

Pedro Sousa

almost 3 years ago
Hello, I’m trying to use Micrometer Tracing in Spring Boot 3.0 with Kotlin, but I think it’s not working the way I expected. From what I read, I thought that tracing information stored in coroutines contexts would flow through the different Threads of execution. But it looks like that once the thread changes, trace information is lost. I’ve created this simple controller to test this:
@RestController
class TestController(val tracer: Tracer) {
    private val logger: Logger = LoggerFactory.getLogger(this::class.java)

    @GetMapping("/test")
    suspend fun test() {
        <http://logger.info|logger.info>("before: ${tracer.currentTraceContext().context()?.traceId()}")
        delay(50)
        <http://logger.info|logger.info>("after: ${tracer.currentTraceContext().context()?.traceId()}")
    }
}
The second log statement reports a null value for the traceId, because the Kotlin
delay
function caused a thread switch and the trace informations is lost, Can anyone help here? Why is this happening? Is it by design? Is there something I can do to guarantee that the traceId is always present?
p
r
  • 2
  • 1
  • 1757
[SOLVED] Anyone else experiencing `unresolved reference` problems in Android Studio or Intellij for ...
i

iamsteveholmes

over 3 years ago
[SOLVED] Anyone else experiencing
unresolved reference
problems in Android Studio or Intellij for Kotlin 1.6.20? I filed a seemingly related issue months ago that was never resolved and it appears to be happening by default in 1.6.20. https://youtrack.jetbrains.com/issue/KT-48148 EDIT: This appears to have been an issue with my settings. I had to install a new intellij without importing settings. I’m working with support to pinpoint the issue.
i
r
a
  • 3
  • 6
  • 1754
Is there any chart library available for compose multiplatform?
j

jamshedalamqaderi

over 2 years ago
Is there any chart library available for compose multiplatform?
j
p
m
  • 3
  • 5
  • 1751
Hi folks. I want to upload a huge multipart file to my server via Ktor Client. Any ideas or tips? Th...
m

Mikhail

over 3 years ago
Hi folks. I want to upload a huge multipart file to my server via Ktor Client. Any ideas or tips? The file is considered to be larger than 2GB.
m
f
+3
  • 5
  • 12
  • 1746
Hi, how can I convert a Swift `NSData` to Kotlin `ByteArray`? Background: I’m working on a Kmp libra...
b

Bao Le Duc

almost 3 years ago
Hi, how can I convert a Swift
NSData
to Kotlin
ByteArray
? Background: I’m working on a Kmp library where we need to use OS’s crypto API to encrypt data. So, in Kmp library we define an Interface
interface MessagePackHelper {
    fun serialize(payload: String): ByteArray
}
from iOS, we need to implement this interface and set back to the Kmp library. So in Swift, we need to implement below method:
func serialize(payload: String) -> KotlinByteArray {
        // let encyrpted = encrypt(payload) // result is NSData obect
        // todo - would like to convert NSData -> KotlinByteArray
    }
b
e
  • 2
  • 5
  • 1737
Previous151617Next

kotlinlang

A modern programming language that makes developers happier.

Powered by