@gtcx/connectivity
v0.3.0
Published
Network connectivity detection and profiling for offline-first applications.
Readme
@gtcx/connectivity
Network connectivity detection and profiling for offline-first applications.
Installation
pnpm add @gtcx/connectivityQuick Start
import { ConnectivityDetector, classifyProfile } from '@gtcx/connectivity';
const detector = new ConnectivityDetector();
const profile = classifyProfile(await detector.check());API
| Export | Description |
| ------------------------- | ----------------------------- |
| ConnectivityDetector | Network state detector |
| classifyProfile(result) | Classify connectivity profile |
| ConnectivityState | Current state type |
Related
License
MIT
