Noob here getting an error which seems to indicate that the saga middleware is not getting loaded properly with the store.
F:\Courses\react-native-redux\managernode_modules\react-native\Libraries\Core\ExceptionsManager.js:71uncaught at check Before running a Saga, you must mount the Saga middleware on the Store using applyMiddleware
Here is my store setup:
/* eslint-disable no-underscore-dangle */
const sagaMiddleware = createSagaMiddleware();
const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION__ || compose;
const store = createStore(
reducers,
initialState,
composeEnhancers(applyMiddleware(sagaMiddleware)),
);
sagaMiddleware.run(sagas);
/* eslint-enable */
/* eslint-disable no-underscore-dangle */
const sagaMiddleware = createSagaMiddleware();
const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION__ || compose;
const store = createStore(
reducers,
initialState,
composeEnhancers(applyMiddleware(sagaMiddleware)),
);
sagaMiddleware.run(sagas);
/* eslint-enable */
If you want to take compose function, should use __REDUX_DEVTOOLS_EXTENSION_COMPOSE__ instead of __REDUX_DEVTOOLS_EXTENSION__ enhancer.
Let me know if it work for you. :)
Nice! Thanks, it works now :) It's interesting that it worked find with 'REDUX_DEVTOOLS_EXTENSION' before using this debugger.
One thing though, I'm still suffering from the very slow animation bug when remote debugging is on. Am I missing another setup somewhere?
Forgot to add that I'm on Windows 10 and using Genymotion.
One thing though, I'm still suffering from the very slow animation bug when remote debugging is on. Am I missing another setup somewhere?
It only happens here but http://localhost: 8081/debugger-ui not? If true the problem may comes from the react inspector? Try to disable setupDevtools of react-native.
It DOES happen at http://localhost: 8081/debugger-ui. That's the main reason why I was trying to find another debugger and found this one.
I'm not sure if that's what you meant but I used 'Toggle React DevTools' from the View menu and there was a small improvement but there is still a big lag.
It DOES happen at http://localhost: 8081/debugger-ui.
Ok, because this project is based on official debugger, it's may still a long-term problem. 馃 (https://github.com/facebook/react-native/issues/5632)
I'm closing this issue because the title problem is resolved.
Most helpful comment
If you want to take compose function, should use
__REDUX_DEVTOOLS_EXTENSION_COMPOSE__instead of__REDUX_DEVTOOLS_EXTENSION__enhancer.Let me know if it work for you. :)