rememberConnectivityState
fun rememberConnectivityState(options: HttpConnectivityOptions = remember { HttpConnectivityOptions() }, scope: CoroutineScope = rememberCoroutineScope(), httpClient: HttpClient = remember { HttpClient() }): ConnectivityState
Create and remember a ConnectivityState instance for Android and iOS platforms.
Return
A ConnectivityState instance.
Parameters
options
The ConnectivityOptions to use for configuring the network status monitoring.
scope
The CoroutineScope in which to launch the network status monitoring coroutine.
httpClient
The HttpClient instance to use for network requests.
fun rememberConnectivityState(scope: CoroutineScope = rememberCoroutineScope(), httpClient: HttpClient = HttpClient(), block: HttpConnectivityOptions.Builder.() -> Unit): ConnectivityState
Create and remember a ConnectivityState instance for Android and iOS platforms.
Return
A ConnectivityState instance.
Parameters
scope
The CoroutineScope in which to launch the network status monitoring coroutine.
httpClient
The HttpClient instance to use for network requests.
block
A lambda function to configure the HttpConnectivityOptions instance.