After reading a bit, I found out that runBlocking ...
# multiplatform
a
After reading a bit, I found out that runBlocking is only available for JVM. Can I assume that await() is also JVM only? If so, how do I refactor my code to maintain the same behavior? Thanks!
m
runBlocking
is available on native as well, but not on JS
unless you use JS, you can use expect/actual to define your own runBlocking
a
Yeah...JS is where I need it
m
I see
a
I'm also getting an "error" with await()....
m
I'm not super familiar with how JS scheduling work
a
Ah!
Ok.
Ok, so now I need to deal with runBlocking....
I found an article that talks about it for testing, but it doesn't mention that it can be use for common code.
Let me try that. Thanks!
m
Sure thing, I didn't do much, I want to dive into JS but haven't really found the time yet
a
What is your usecase of using runBlocking on js?