0.2.0 • Published 4 years ago

react-offline-grayscale v0.2.0

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

react-offline-grayscale

Make your react app respond when offline.

NPM JavaScript Style Guide

Install

using npm:

npm install --save react-offline-grayscale

using yarn:

yarn add react-offline-grayscale

Usage

Root component

import React from 'react'
import ReactDOM from 'react-dom'
import App from './App'
import ReactOffline from 'react-offline-grayscale'

ReactDOM.render(
	<ReactOffline>
		<App />
	</ReactOffline>,
	document.getElementById('root'),
)

Props

nametyperequireddefaultdescription
enableClickbooleanfalsefalsedecides if clicks are allowed on offline
filterstringfalsegrayscalefilter to applied on the document
barStyleobjectfalsestyle object for offline indication bar
customPageStyleobjectfalsestyle object for document applied on offline
customOfflineTextstringfalseYou are offlineText for offline indication

License

Contributing

Pull Requests are very welcome!

License

MIT © mrinalraj