Commit a50bf1b1 authored by Andrew Hrdy's avatar Andrew Hrdy

Fixed error with compose in index.js.

parent b50d4f42
Pipeline #2018 passed with stage
in 1 minute and 39 seconds
......@@ -19,7 +19,12 @@ const history = createHistory();
const extension = window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__();
const isProduction = process.env.NODE_ENV === 'production';
const enhance = compose(applyMiddleware(ReduxThunk, routerMiddleware(history)), !isProduction && extension);
let enhance;
if (isProduction) {
enhance = compose(applyMiddleware(ReduxThunk, routerMiddleware(history)));
} else {
enhance = compose(applyMiddleware(ReduxThunk, routerMiddleware(history)), extension);
}
if (isProduction) {
window.dataLayer = window.dataLayer || [];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment