https://kotlinlang.org logo
#ios
Title
# ios
m

Mikołaj Kąkol

10/07/2020, 2:15 PM
Hello, any recommendations for making api call in common code while api call is implemented in ios? Currently we are thinking about interface like this
Copy code
expect fun fetch(result : (String) -> Unit)
However this can lead to freezing issue, since callback can be called on different thread. Any suggestions?
s

Sam

10/07/2020, 6:35 PM
Use GCD to dispatch the callback onto the proper thread?