react-native-nitro-network-info
Version:
A React Native library for monitoring network connectivity status and connection type using Nitro Modules for high performance
8 lines (7 loc) • 364 B
text/typescript
import { type HybridObject } from 'react-native-nitro-modules'
import type { ConnectionType, NetworkInfoListener } from '../types'
export interface NitroNetworkInfo extends HybridObject<{ ios: 'swift', android: 'kotlin' }> {
readonly isConnected: boolean
readonly connectionType: ConnectionType
addListener(listener: NetworkInfoListener): () => void
}