Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/avraammavridis/react-network-info
HoC providing info about the network conditions
https://github.com/avraammavridis/react-network-info
connection high-order-component network react
Last synced: 21 days ago
JSON representation
HoC providing info about the network conditions
- Host: GitHub
- URL: https://github.com/avraammavridis/react-network-info
- Owner: AvraamMavridis
- Created: 2017-10-23T20:43:08.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2020-05-27T06:18:13.000Z (over 4 years ago)
- Last Synced: 2024-10-11T06:30:00.896Z (about 1 month ago)
- Topics: connection, high-order-component, network, react
- Language: JavaScript
- Homepage: https://avraammavridis.github.io/react-network-info/
- Size: 7.1 MB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# HoC providing info about the network conditions
### [Demo](https://avraammavridis.github.io/react-network-info/)
[![Build Status](https://travis-ci.org/AvraamMavridis/react-network-info.svg?branch=master)](https://travis-ci.org/AvraamMavridis/react-network-info) [![Greenkeeper badge](https://badges.greenkeeper.io/AvraamMavridis/react-network-info.svg)](https://greenkeeper.io/)
Install the component
```js
import NetworkInformation from 'react-network-info';
```Wrap your components with it
```js
Something
```
It provides to the children/wrapped components the following props:
| Prop | Descriptipn |
| ------------- |-------------|
| downlink | The effective bandwidth estimate in megabits per second, rounded to the nearest multiple of 25 kilobits per seconds. |
| effectiveType | The effective type of the connection meaning one of 'slow-sg', '2g', '3g', or '4g' |
| rtt | The estimated effective round-trip time of the current connection |