react-connection-notification
v0.1.2
Published
React internet status notification
Downloads
2
Maintainers
Readme
Notification component to display internet connection status
Prerequisites
- node >=10
Previews
Install
Development
npm install
npm start
Run tests
npm run test
Usage
import ConnectionNotification from 'react-connection-notification'
<ConnectionNotification/>
Properties
| Name | Type | Default | Description | | --- | --- | --- | --- | | position | 'top-right' or 'top-left' or 'bottom-right' or 'bottom-left' | bottom-left | position of notification | | hideDismissButton | Boolean | false | hide dismiss button of notification | | hideIcon | Boolean | false | hide connection icon | | onlineText | String | "You are online now" | Online status text | | offlineText | String | "You are offline now" | Offline status text | | onlineIcon | String | wifi-icon | Online status icon | | offlineIcon | String | no-wifi-icon | Offline status icon | | duration | Number | 2000 | duration of notification. After duration, it will be hided | | disableDuration | Boolean | false | Disable duration and notification will be visible until user clicks dismiss button | | style | Object | {} | Custom styles |
Author
👤 Cem Karakurt
Website: https://cemkarakurt.com
Twitter: @ickarakurt
Github: @ickarakurt
LinkedIn: @ickarakurt
Show your support
Give a ⭐️ if this project helped you!