blob: ad0427b52f319cb93014009ae2ae9d991f2c7c49 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
import { createStore, applyMiddleware, compose } from 'redux';
import thunk from 'redux-thunk';
import appReducer from '../reducers';
import loadingBarMiddleware from '../middleware/loading_bar';
import errorsMiddleware from '../middleware/errors';
import soundsMiddleware from 'redux-sounds';
import Howler from 'howler';
import Immutable from 'immutable';
Howler.mobileAutoEnable = false;
const soundsData = {
boop: '/sounds/boop.mp3'
};
export default function configureStore() {
return createStore(appReducer, compose(applyMiddleware(
thunk,
loadingBarMiddleware({ promiseTypeSuffixes: ['REQUEST', 'SUCCESS', 'FAIL'] }),
errorsMiddleware(),
soundsMiddleware(soundsData)
), window.devToolsExtension ? window.devToolsExtension() : f => f));
};
|