Cannot use react devtools & redux devtools in build version of CRA

327 Views Asked by At

Using create-react-app with redux, and having both extension installed in chrome, I'm able to debug my app with these two.

However, after building my app npm run build the two extensions are not working.

Loading the redux devtools is with:

const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose;
...
const store = createStore(
  combineReducers(...reducers),
  preloadedState,
  composeEnhancers(applyMiddleware(...middlewares)),
);
0

There are 0 best solutions below