Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jsonnull/redux-render
Ergonomic Redux bindings for React using render functions
https://github.com/jsonnull/redux-render
react reactjs redux render-props
Last synced: 9 days ago
JSON representation
Ergonomic Redux bindings for React using render functions
- Host: GitHub
- URL: https://github.com/jsonnull/redux-render
- Owner: jsonnull
- License: mit
- Archived: true
- Created: 2017-09-25T17:04:15.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2021-10-16T04:30:50.000Z (about 3 years ago)
- Last Synced: 2024-09-22T00:45:25.310Z (about 2 months ago)
- Topics: react, reactjs, redux, render-props
- Language: JavaScript
- Homepage:
- Size: 116 KB
- Stars: 54
- Watchers: 3
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-react-render-props - redux-render
- awesome-react-render-props - redux-render
README
# Redux Render
[![Build Status](https://travis-ci.org/jsonnull/redux-render.svg?branch=master)](https://travis-ci.org/jsonnull/redux-render)
[![Coverage Status](https://coveralls.io/repos/github/jsonnull/redux-render/badge.svg?branch=master)](https://coveralls.io/github/jsonnull/redux-render?branch=master)
[![npm version](https://img.shields.io/npm/v/redux-render.svg)](https://www.npmjs.com/package/redux-render)React bindings for Redux using render props.
```JavaScript
const Title = () => (
state.title}>
{title => (
{title}
)}
)
```## Why use this?
Render props afford you a lot of flexibility over Higher-Order Components (HOCs).
- **Reactivity**: Change selectors or dispatch calls on the fly as your component state and props change.
- **Brevity**: It starts at just one line of code to connect to Redux in a performant way.
- **Flexibility**: Using render props, you can easily create HOCs to support your own use-cases.## Installation
```sh
yarn add redux-render# npm install --save redux-render
```## Examples
- Controlled input ([source](examples/), [CodeSandbox](https://codesandbox.io/s/vnk2qzov65))
## [API](docs/API.md)
- [``](docs/API.md#provider-store)
- [``](docs/API.md#redux-selector-children)