Batch React updates that occur as a result of Redux dispatches, to prevent cascading renders

Overview

redux-batched-updates

build status npm version

Batch React updates that occur as a result of Redux dispatches, to prevent cascading renders. See https://github.com/gaearon/redux/issues/125 for more details.

npm install --save redux-batched-updates

Usage

// Use as higher-order store
import { batchedUpdates } from 'redux-batched-updates';
const store = batchedUpdates(createStore)(reducer, intialState);

// Or as middleware
import { batchedUpdatesMiddleware } from 'redux-batched-updates';
const m = composeMiddleware(thunk, promise, batchedUpdatesMiddleware);
const store = applyMiddleware(m)(createStore)(reducer, initialState)
You might also like...
Front-end of the movie application created with React.js and Redux
Front-end of the movie application created with React.js and Redux

# Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run:

Recipe Catalogue is a React & Redux web app based on a catalog of recipes.
Recipe Catalogue is a React & Redux web app based on a catalog of recipes.

Recipe Catalogue is a React & Redux web app based on a catalog of recipes. It contains a browsable list of meals that you can filter by category or type and access to one meal recipe. The data is retrieved from [Meals DB (https://www.themealdb.com/api.php) and then stored in the Redux store.

The ultimate React SSR, Redux-powered example.
The ultimate React SSR, Redux-powered example.

Redux server-side The ultimate React SSR, Redux-powered example. But why? Does any of the following sentences describe your SSR adventures? You'd love

This command line helps you create components, pages and even redux implementation for your react project
This command line helps you create components, pages and even redux implementation for your react project

react-help-create This command line helps you create components, pages and even redux implementation for your react project. How to install it? To ins

A sample React TypeScript Redux Toolkit CRUD app
A sample React TypeScript Redux Toolkit CRUD app

A sample React TypeScript Redux Toolkit CRUD app

Redux-Toolkit example with React Hooks CRUD Application, Axios, Rest API, Bootstrap
Redux-Toolkit example with React Hooks CRUD Application, Axios, Rest API, Bootstrap

Redux-Toolkit example with React Hooks CRUD Application, Axios, Rest API, Bootstrap

Notas de estudo sobre o workflow de implementação do React Redux Toolkit.

Resumo: Redux Toolkit Este projeto foi criado com Create React App, usando o Redux e Redux Toolkit como modelos. Documentação: https://redux-toolkit.j

Pomofocus clone built with React, Redux, & Firebase [WIP]
Pomofocus clone built with React, Redux, & Firebase [WIP]

Pomofocus Clone Pomodoro Timer Pomofocus is a customizable pomodoro timer that works on desktop & mobile browser. The aim of this app is to help you f

Single page application for tracking cryptocurrencies. Includes sorting, animations, graphs and more. Made using React & Redux.
Single page application for tracking cryptocurrencies. Includes sorting, animations, graphs and more. Made using React & Redux.

Crypto Tracker A single page application meant to keep track of the most popular crypto currencies status. The user can sort the coins by highest gain

Comments
  • Upgraded logic to work with React v0.14

    Upgraded logic to work with React v0.14

    Upgraded to work with React v0.14

    Changes

    • Upgraded react dependency
    • Added react-dom dependency
    • Now uses unstable_batchedUpdates rather than the batchedUpdates-addon

    Tests:

    • Uses the renderSpy to pass results back to the test. React does not like that we access the props of the rendered div
    opened by PAkerstrand 0
  • The addon is removed in 0.15

    The addon is removed in 0.15

    The batchedUpdates addon is removed, does that mean the issue does not exist anymore?

    https://facebook.github.io/react/blog/2016/03/07/react-v15-rc1.html#breaking-changes

    Maybe a good idea to note that in the readme

    opened by EECOLOR 3
  • Update to support React 0.14

    Update to support React 0.14

    Running this with React 0.14 gives the following warnings:

    Warning: require('react/addons') is deprecated. Access using require('react-addons-{addon}') instead.
    warning.js
    Warning: React.addons.batchedUpdates is deprecated. Use ReactDOM.unstable_batchedUpdates instead.
    
    opened by bengillies 5
  • Dispatch returns undefined in certain cases.

    Dispatch returns undefined in certain cases.

    I brought up this issue in rackt/redux#481.

    Im not sure if this can be solved from a code point of view but it might be worth documenting the issue with dispatch result being undefined in certain cases.

    • middleware needs to come after thunk, promise or any middleware where you expect a value to be returned.
    • with non-thunk actions you will not be able to access the return value.

    Perhaps worth listing redux-batched-subscribe as an alternative.

    opened by tappleby 1
Owner
Andrew Clark
React core at Facebook. Hi!
Andrew Clark
A lightweight state management library for react inspired by redux and react-redux

A lightweight state management library for react inspired by redux and react-redux

null 2 Sep 9, 2022
A Higher Order Component using react-redux to keep form state in a Redux store

redux-form You build great forms, but do you know HOW users use your forms? Find out with Form Nerd! Professional analytics from the creator of Redux

Redux Form 12.6k Jan 3, 2023
A simple app for study react with redux, redux saga and typescript.

React com Redux, Redux-Saga e TypeScript. ?? Uma aplicação simple para entender o funcionamento do Redux e a melhor maneira de utiliza-lo junto com o

João Marcos Belanga 1 May 24, 2022
Redux - Create forms using Redux And React

Exercício de fixação Vamos criar formulários utilizando Redux! \o/ Antes de inic

Márcio Júnior 2 Jul 21, 2022
redux-immutable is used to create an equivalent function of Redux combineReducers that works with Immutable.js state.

redux-immutable redux-immutable is used to create an equivalent function of Redux combineReducers that works with Immutable.js state. When Redux creat

Gajus Kuizinas 1.9k Dec 30, 2022
A chart monitor for Redux DevTools https://www.npmjs.com/package/redux-devtools-chart-monitor

Redux DevTools Chart Monitor This package was merged into redux-devtools monorepo. Please refer to that repository for the latest updates, issues and

Redux 293 Nov 13, 2022
An i18n solution for React/Redux and React Native projects

redux-react-i18n An i18n solution with plural forms support for Redux/React Workers of all countries, unite! Supported languages list with expected co

Dmitry Erzunov 64 Oct 19, 2022
Official React bindings for Redux

React Redux Official React bindings for Redux. Performant and flexible. Installation Using Create React App The recommended way to start new apps with

Redux 22.5k Jan 1, 2023
Ruthlessly simple bindings to keep react-router and redux in sync

Project Deprecated This project is no longer maintained. For your Redux <-> Router syncing needs with React Router 4+, please see one of these librari

React Community 7.9k Dec 30, 2022
A Soundcloud client built with React / Redux

SoundRedux NOTE It seems that SoundCloud has revoked my api client keys without any explanation or warning. Running the app locally no longer works un

Andrew Nguyen 5k Dec 22, 2022