aboutsummaryrefslogtreecommitdiffstats
path: root/development/uiStore.js
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2016-07-22 09:08:35 +0800
committerDan Finlay <dan@danfinlay.com>2016-07-22 09:08:35 +0800
commit5b4e2ffeaccf105d425d83407b82805c124e2cca (patch)
treee2a9e90a064e09c48eac089901a1951458213e1b /development/uiStore.js
parent0bbfedc2bf21d8c3eec17fef35e93a98a946469e (diff)
downloadtangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.tar
tangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.tar.gz
tangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.tar.bz2
tangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.tar.lz
tangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.tar.xz
tangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.tar.zst
tangerine-wallet-browser-5b4e2ffeaccf105d425d83407b82805c124e2cca.zip
Add mock dev mode
Diffstat (limited to 'development/uiStore.js')
-rw-r--r--development/uiStore.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/development/uiStore.js b/development/uiStore.js
new file mode 100644
index 000000000..1299ee1dc
--- /dev/null
+++ b/development/uiStore.js
@@ -0,0 +1,18 @@
+const createStore = require('redux').createStore
+const applyMiddleware = require('redux').applyMiddleware
+const thunkMiddleware = require('redux-thunk')
+const createLogger = require('redux-logger')
+const rootReducer = require('../ui/app/reducers')
+
+module.exports = configureStore
+
+const loggerMiddleware = createLogger()
+
+const createStoreWithMiddleware = applyMiddleware(
+ thunkMiddleware,
+ loggerMiddleware
+)(createStore)
+
+function configureStore (initialState) {
+ return createStoreWithMiddleware(rootReducer, initialState)
+}