client/src/reducers/index.js
author salimr <riwad.salim@yahoo.fr>
Mon, 08 Oct 2018 03:24:47 +0200
changeset 159 a4705c2b4544
parent 134 be36eed5e6e0
child 168 ea92f4fe783d
permissions -rw-r--r--
Add send note options to the editor

import { combineReducers } from 'redux-immutable';
import { routerReducer } from 'react-router-redux';

import notes from './notesReducer';
import { sessions } from './sessionsReducer';
import { isAuthenticated, currentUser, currentGroup, login, register, token, groups, createGroup, clientId } from './authReducer';
import { autoSubmit, online } from './miscReducer';
import { isSynchronizing, lastSync } from './syncReducer';


const rootReducer = combineReducers({
  sessions,
  notes,
  login,
  register,
  authStatus: combineReducers({
    token,
    currentUser,
    currentGroup,
    isAuthenticated,
    clientId,
    lastSync
  }),
  status: combineReducers({
    isSynchronizing,
    online
  }),
  router: routerReducer,
  autoSubmit,
  groups,
  createGroup,
});


export default rootReducer;