From e080deae4b42a506e6000d2f8e630c60bd63e539 Mon Sep 17 00:00:00 2001 From: Jori Lallo Date: Sun, 28 Feb 2016 22:15:25 -0800 Subject: [PATCH] index.js sections --- src/index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/index.js b/src/index.js index c324c4d1..5438401a 100644 --- a/src/index.js +++ b/src/index.js @@ -15,6 +15,8 @@ import App from './Views/App'; import Login from './Views/Login'; import Dashboard from './Views/Dashboard'; +// Redux + const reducer = storage.reducer(reducers); const engine = createEngine('atlas-store'); const storageMiddleware = storage.createMiddleware(engine); @@ -27,6 +29,8 @@ load(store) .then((newState) => console.log('Loaded state:', newState)) .catch(() => console.log('Failed to load previous state')); +// React router + function requireAuth(nextState, replace) { if (!Auth.loggedIn()) { replace({