Advertisement
Guest User

Untitled

a guest
Apr 20th, 2019
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. import { batch } from "react-redux";
  2.  
  3. function miThunk() {
  4. return (dispatch, getState) => {
  5. // Esto solo debe renderizar el componente una vez, no dos.
  6. batch(() => {
  7. dispatch(aumentar());
  8. dispatch(aumentar());
  9. })
  10. }
  11. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement