You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This gives you access to Android [Dispatchers.Main]
155
-
coroutine dispatcher and also makes sure that in case of crashed coroutine with unhandled exception this
156
-
exception is logged before crashing Android application, similarly to the way uncaught exceptions in
157
-
threads are handled by Android runtime.
138
+
This gives you access to the Android [Dispatchers.Main]
139
+
coroutine dispatcher and also makes sure that in case of a crashed coroutine with an unhandled exception that
140
+
this exception is logged before crashing the Android application, similarly to the way uncaught exceptions in
141
+
threads are handled by the Android runtime.
158
142
159
143
#### R8 and ProGuard
160
144
@@ -165,8 +149,9 @@ For more details see ["Optimization" section for Android](ui/kotlinx-coroutines-
165
149
166
150
The `kotlinx-coroutines-core` artifact contains a resource file that is not required for the coroutines to operate
167
151
normally and is only used by the debugger. To exclude it at no loss of functionality, add the following snippet to the
168
-
`android` block in your gradle file for the application subproject:
169
-
```groovy
152
+
`android` block in your Gradle file for the application subproject:
153
+
154
+
```kotlin
170
155
packagingOptions {
171
156
resources.excludes +="DebugProbesKt.bin"
172
157
}
@@ -177,23 +162,24 @@ packagingOptions {
177
162
Core modules of `kotlinx.coroutines` are also available for
178
163
[Kotlin/JS](https://kotlinlang.org/docs/reference/js-overview.html) and [Kotlin/Native](https://kotlinlang.org/docs/reference/native-overview.html).
179
164
180
-
In common code that should get compiled for different platforms, you can add dependency to `kotlinx-coroutines-core` right to the `commonMain` source set:
181
-
```groovy
165
+
In common code that should get compiled for different platforms, you can add a dependency to `kotlinx-coroutines-core` right to the `commonMain` source set:
(follow the link to get the dependency declaration snippet) and as [`kotlinx-coroutines-core`](https://www.npmjs.com/package/kotlinx-coroutines-core) NPM package.
198
184
199
185
#### Native
@@ -202,14 +188,6 @@ Kotlin/Native version of `kotlinx.coroutines` is published as
202
188
[`kotlinx-coroutines-core-$platform`](https://mvnrepository.com/search?q=kotlinx-coroutines-core-) where `$platform` is
203
189
the target Kotlin/Native platform. [List of currently supported targets](https://github.com/Kotlin/kotlinx.coroutines/blob/master/gradle/compile-native-multiplatform.gradle#L16).
204
190
205
-
206
-
Only single-threaded code (JS-style) on Kotlin/Native is supported in stable versions.
207
-
Additionally, special `-native-mt` version is released on a regular basis, for the state of multi-threaded coroutines support
208
-
please follow the [corresponding issue](https://github.com/Kotlin/kotlinx.coroutines/issues/462) for the additional details.
209
-
210
-
Since Kotlin/Native does not generally provide binary compatibility between versions,
211
-
you should use the same version of Kotlin/Native compiler as was used to build `kotlinx.coroutines`.
0 commit comments