I am trying to check the code using the flowtype type:
export default function configureStore(initialState: initialStateType) {
if (module && module.hot) {
module.hot.accept('../reducers', () => {
const nextRootReducer = require('../reducers');
store.replaceReducer(nextRootReducer);
});
}
}
And I get this error message:
src/store/configureStore.js:14
14: module.hot.accept('../reducers', () => {
^ call of method `accept`. Method cannot be called on
14: module.hot.accept('../reducers', () => {
^^^^^^^^^^ property `hot` of unknown type
How can i fix this?
Thank!
source
share