diff options
Diffstat (limited to 'openecomp-ui/src/sdc-app/AppStore.js')
-rw-r--r-- | openecomp-ui/src/sdc-app/AppStore.js | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/openecomp-ui/src/sdc-app/AppStore.js b/openecomp-ui/src/sdc-app/AppStore.js index bafef7dcd6..bca750a930 100644 --- a/openecomp-ui/src/sdc-app/AppStore.js +++ b/openecomp-ui/src/sdc-app/AppStore.js @@ -14,24 +14,27 @@ * limitations under the License. */ -import {createStore, applyMiddleware, compose} from 'redux'; +import { createStore, applyMiddleware, compose } from 'redux'; import Reducers from './Reducers.js'; const thunk = store => next => action => - typeof action === 'function' ? - action(store.dispatch, store.getState) : - next(action); - + typeof action === 'function' + ? action(store.dispatch, store.getState) + : next(action); const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose; -export const storeCreator = (initialState) => createStore(Reducers, initialState, composeEnhancers(applyMiddleware(thunk))); - +export const storeCreator = initialState => + createStore( + Reducers, + initialState, + composeEnhancers(applyMiddleware(thunk)) + ); const store = storeCreator(); if (module.hot) { - module.hot.accept('./Reducers.js', () => - store.replaceReducer(require('./Reducers.js').default) - ); + module.hot.accept('./Reducers.js', () => + store.replaceReducer(require('./Reducers.js').default) + ); } export default store; |