parakhod / react-navigation-redux-debouncer

Debounce middleware for the react-navigation redux actions
MIT License
39 stars 2 forks source link

Lol - I got issue here man, kindly sugest how to resolve it. #2

Open PManager1 opened 6 years ago

PManager1 commented 6 years ago

image

import navigationDebouncer from 'react-navigation-redux-debouncer';

import { createStore, compose, applyMiddleware } from 'redux'; import thunk from 'redux-thunk'; import reducers from '../reducers';

const store = createStore( reducers, {}, compose ( applyMiddleware (navigationDebouncer( 600 )) (thunk) ) );

export default store;

DriesVS commented 6 years ago

The applyMiddleware function wants an array of middlewares, like so: applyMiddleware ([navigationDebouncer(600), thunk])

https://redux.js.org/api-reference/applymiddleware

This can be closed since it has no relevance to this library @parakhod