From 408d85f19af34fc3aa448f3396d79fbb6899d3ab Mon Sep 17 00:00:00 2001 From: Szymon Lesisz Date: Mon, 3 Sep 2018 17:47:15 +0200 Subject: [PATCH] logger is back --- src/store.js | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/store.js b/src/store.js index b69d1243..bae277fb 100644 --- a/src/store.js +++ b/src/store.js @@ -37,10 +37,22 @@ if (process.env.NODE_ENV === 'development') { // return pass.length === 0; // }; + const logger = createLogger({ + level: 'info', + predicate: excludeLogger, + collapsed: true, + }); + + const devToolsExtension: ?Function = window.devToolsExtension; + if (typeof devToolsExtension === 'function') { + enhancers.push(devToolsExtension()); + } + composedEnhancers = compose( - applyMiddleware(...middleware, ...services), + applyMiddleware(logger, ...middleware, ...services), ...enhancers, ); + } else { composedEnhancers = compose( applyMiddleware(...middleware, ...services),