The observable that emits true if the device is connected to the network, and emits false if the device is disconnected from the network.
true
false
import retryWhen from 'react-executor/plugin/retryWhen';import navigatorOnline from 'react-executor/observable/navigatorOnline';const executor = useExecutor('test', heavyTask, [ retryWhen(navigatorOnline)]); Copy
import retryWhen from 'react-executor/plugin/retryWhen';import navigatorOnline from 'react-executor/observable/navigatorOnline';const executor = useExecutor('test', heavyTask, [ retryWhen(navigatorOnline)]);
The observable that emits
true
if the device is connected to the network, and emitsfalse
if the device is disconnected from the network.