@akbeniwal/react-native-smart-netinfo 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# react-native-smart-netinfo
|
|
1
|
+
# @akbeniwal/react-native-smart-netinfo
|
|
2
2
|
|
|
3
3
|
A lightweight, zero-dependency, smart network connection monitor for React Native and React Native Web. It keeps track of device connectivity, measures latency (ping), rates the connection quality, and automatically/manually estimates download speeds in Mbps.
|
|
4
4
|
|
|
@@ -19,10 +19,10 @@ A lightweight, zero-dependency, smart network connection monitor for React Nativ
|
|
|
19
19
|
|
|
20
20
|
```bash
|
|
21
21
|
# Using npm
|
|
22
|
-
npm install react-native-smart-netinfo
|
|
22
|
+
npm install @akbeniwal/react-native-smart-netinfo
|
|
23
23
|
|
|
24
24
|
# Using yarn
|
|
25
|
-
yarn add react-native-smart-netinfo
|
|
25
|
+
yarn add @akbeniwal/react-native-smart-netinfo
|
|
26
26
|
```
|
|
27
27
|
|
|
28
28
|
---
|
|
@@ -34,7 +34,7 @@ yarn add react-native-smart-netinfo
|
|
|
34
34
|
Subscribe to network state updates anywhere in your app:
|
|
35
35
|
|
|
36
36
|
```typescript
|
|
37
|
-
import { SmartNetInfo, NetworkState } from 'react-native-smart-netinfo';
|
|
37
|
+
import { SmartNetInfo, NetworkState } from '@akbeniwal/react-native-smart-netinfo';
|
|
38
38
|
|
|
39
39
|
// (Optional) Configure settings
|
|
40
40
|
SmartNetInfo.configure({
|
|
@@ -66,7 +66,7 @@ Create a custom hook to use `SmartNetInfo` easily in your React Native component
|
|
|
66
66
|
|
|
67
67
|
```tsx
|
|
68
68
|
import { useEffect, useState } from 'react';
|
|
69
|
-
import { SmartNetInfo, NetworkState } from 'react-native-smart-netinfo';
|
|
69
|
+
import { SmartNetInfo, NetworkState } from '@akbeniwal/react-native-smart-netinfo';
|
|
70
70
|
|
|
71
71
|
export function useNetworkStatus() {
|
|
72
72
|
const [status, setStatus] = useState<NetworkState>({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akbeniwal/react-native-smart-netinfo",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "A lightweight smart network monitoring library for React Native with internet reachability, latency monitoring, connection quality detection and speed testing.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|