An open API service indexing awesome lists of open source software.

https://github.com/shankytiwari/react-browser-to-props

A HOC Components with Web API support for React Components
https://github.com/shankytiwari/react-browser-to-props

browser-api-props local-storage-to-props react-browser-to-props web-api-react-props web-api-to-props

Last synced: 7 months ago
JSON representation

A HOC Components with Web API support for React Components

Awesome Lists containing this project

README

          

# react-browser-to-props
A HOC Components with Web API support for React Components

## Why react-browser-to-props?

The main goal of this package is to deliver High Order Component which consumes daily use WebAPIs such as LocalStorage, Cookie Storage, and some common utility functions such as reading the query params, that can fit into any kind of project with no muss, no fuss.

## Demo

Check the Month picker in action, [click here](https://react-fljxsu.stackblitz.io/?name=Shashank&lastname=tiwari).

## Install
You can use either the npm or yarn command-line tool to install packages. Use whichever is appropriate for your project in the examples below.

#### NPM
```bash
npm install --save react-browser-to-props
```
#### YARN
```
yarn add --save react-browser-to-props
```

## Usage

```tsx

import BrowserToProps from 'react-browser-to-props';

const App = (props) => {
console.log(props)
return (


Check the console

);
};

const NewComponent = BrowserToProps(App);

ReactDOM.render(
,
document.getElementById('root')
);
```

## Thanks

This Project is build using [tsdx](https://github.com/jaredpalmer/tsdx).

## License

MIT © [ShankyTiwari](https://github.com/ShankyTiwari)