I'm trying to integrate redux-tooltip with my map but am running into issues, - I think it's to do with how the reducer is set up. Here's my map component:
import { reducer as tooltip } from "redux-tooltip"
const rootReducer = combineReducers({
...other reducers here,
tooltip
})
Then my store:
import rootReducer from './redux/reducers'
import thunk from "redux-thunk";
const store = createStore(rootReducer, compose(
applyMiddleware(thunk),
window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__()
));
The error I'm getting says 'Uncaught TypeError: Cannot read property 'bool' of undefined',
and it's because one of the prop types, show, in the Tooltip component is failing. I would assume this is passed by the show and hide actions, but that's clearly not working. Can you help me see where I'm going wrong?
I'm trying to integrate redux-tooltip with my map but am running into issues, - I think it's to do with how the reducer is set up. Here's my map component:
Then you have my rootReducer:
Then my store:
The error I'm getting says 'Uncaught TypeError: Cannot read property 'bool' of undefined', and it's because one of the prop types, show, in the Tooltip component is failing. I would assume this is passed by the show and hide actions, but that's clearly not working. Can you help me see where I'm going wrong?